Method and apparatus for video decoding, and method and apparatus for video encoding

ABSTRACT

Provided are a method and apparatus for performing intra prediction, in a video encoding and decoding procedure, by configuring an additional mode set based on most probable mode (MPM) modes of a current block, and determining an intra prediction mode of the current block, based on the MPM modes and the additional mode set. To solve the technical problems, a video decoding method provided in the present disclosure includes configuring an additional mode set based on MPM modes of a current block; determining an intra prediction mode of the current block, based on the MPM modes and the additional mode set; and performing intra prediction on the current block, based on the intra prediction mode.

CROSS REFERENCE TO RELATED APPLICATIONS

This application is a Continuation Application of U.S. application Ser.No. 16/651,126 filed Mar. 26, 2020, which is a National Stage ofInternational Application No. PCT/KR2018/012311 filed Oct. 18, 2018,which claims priority to U.S. Provisional Application No. 62/573,915filed Oct. 18, 2017, the entire contents of which are incorporatedherein by reference.

TECHNICAL FIELD

The present disclosure relates to a video decoding method and a videodecoding apparatus, and provides a method and apparatus for configuringan additional mode set based on most probable mode (MPM) modes of acurrent block, determining an intra prediction mode of the current blockbased on the MPM modes and the additional mode set, and thus performingintra prediction on the current block.

BACKGROUND ART

Image data is encoded by a preset codec conforming to a data compressionstandard, e.g., the Moving Picture Expert Group (MPEG) standard, andthen is stored in a recording medium or transmitted through acommunication channel in the form of a bitstream.

As hardware capable of reproducing and storing high-resolution orhigh-quality image content has been developed and become widely popular,a codec capable of efficiently encoding or decoding the high-resolutionor high-quality image content is in high demand. The encoded imagecontent may be reproduced by decoding it. Recently, methods ofeffectively compressing high-resolution or high-quality image contentare used. For example, a method of randomly splitting an image to beencoded or a procedure of manipulating data is proposed to allow animage compression technique to be effectively implemented.

As one of data manipulation techniques, it is general, in intraprediction, to use at least two most probable mode (MPM) modes and tocode data and perform signaling under the same conditions in othermodes.

DESCRIPTION OF EMBODIMENTS Technical Problem

Provided are a method and apparatus for configuring an additional modeset based on most probable mode (MPM) modes of a current block,determining an intra prediction mode based on the MPM modes and theconfigured additional mode set, and performing prediction on the currentblock according to the determined intra prediction mode.

Solution to Problem

To solve the technical problems, a video decoding method provided in thepresent disclosure includes configuring an additional mode set based onmost probable mode (MPM) modes of a current block; determining an intraprediction mode of the current block, based on the MPM modes and theadditional mode set; and performing intra prediction on the currentblock, based on the intra prediction mode.

To solve the technical problems, a video decoding apparatus provided inthe present disclosure includes a memory; and at least one processorconnected with the memory, wherein the at least one processor isconfigured to configure an additional mode set based on MPM modes of acurrent block, determine an intra prediction mode of the current block,based on the MPM modes and the additional mode set, and perform intraprediction on the current block, based on the intra prediction mode.

To solve the technical problems, a video encoding method provided in thepresent disclosure includes configuring an additional mode set based onMPM modes of a current block; determining an intra prediction mode ofthe current block, based on the MPM modes and the additional mode set;and performing intra prediction on the current block, based on the intraprediction mode.

To solve the technical problems, a video encoding apparatus provided inthe present disclosure includes a memory; and at least one processorconnected with the memory, wherein the at least one processor isconfigured to configure an additional mode set based on MPM modes of acurrent block, determine an intra prediction mode of the current block,based on the MPM modes and the additional mode set, and perform intraprediction on the current block, based on the intra prediction mode.

Advantageous Effects of Disclosure

In a video encoding and decoding procedure, an additional mode set maybe configured based on most probable mode (MPM) modes of a currentblock, and then prediction may be performed on the current block byusing an intra prediction mode determined based on the MPM modes and theadditional mode set, such that performance may be enhanced due toaccuracy in intra prediction, a bit amount occurring in the coding basedon the intra prediction mode may be decreased, and thus, efficiency inmode signaling may be increased and reliability may be increased.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a schematic block diagram of an image decoding apparatus,according to an embodiment.

FIG. 2 is a flowchart of an image decoding method, according to anembodiment.

FIG. 3 illustrates a process, performed by an image decoding apparatus,of determining at least one coding unit by splitting a current codingunit, according to an embodiment.

FIG. 4 illustrates a process, performed by the image decoding apparatus,of determining at least one coding unit by splitting a non-square codingunit, according to an embodiment.

FIG. 5 illustrates a process, performed by the image decoding apparatus,of splitting a coding unit based on at least one of block shapeinformation and split shape mode information, according to anembodiment.

FIG. 6 illustrates a method, performed by the image decoding apparatus,of determining a preset coding unit from among an odd number of codingunits, according to an embodiment.

FIG. 7 illustrates an order of processing a plurality of coding unitswhen the image decoding apparatus determines the plurality of codingunits by splitting a current coding unit, according to an embodiment.

FIG. 8 illustrates a process, performed by the image decoding apparatus,of determining that a current coding unit is to be split into an oddnumber of coding units, when the coding units are not processable in apreset order, according to an embodiment.

FIG. 9 illustrates a process, performed by the image decoding apparatus,of determining at least one coding unit by splitting a first codingunit, according to an embodiment.

FIG. 10 illustrates that a shape into which a second coding unit issplittable by the image decoding apparatus is restricted when a secondcoding unit having a non-square shape, which is determined by splittinga first coding unit, satisfies a preset condition, according to anembodiment.

FIG. 11 illustrates a process, performed by the image decodingapparatus, of splitting a square coding unit when split shape modeinformation indicates that the square coding unit is not to be splitinto four square coding units, according to an embodiment.

FIG. 12 illustrates that a processing order between a plurality ofcoding units may be changed depending on a process of splitting a codingunit, according to an embodiment.

FIG. 13 illustrates a process of determining a depth of a coding unit asa shape and a size of the coding unit change, when the coding unit isrecursively split such that a plurality of coding units are determined,according to an embodiment.

FIG. 14 illustrates depths that are determinable based on shapes andsizes of coding units, and part indexes (PIDs) that are fordistinguishing the coding units, according to an embodiment.

FIG. 15 illustrates that a plurality of coding units are determinedbased on a plurality of preset data units included in a picture,according to an embodiment.

FIG. 16 illustrates a processing block serving as a unit for determininga determination order of reference coding units included in a picture,according to an embodiment.

FIG. 17 illustrates a block diagram of a video decoding apparatus,according to an embodiment.

FIG. 18 illustrates a flowchart of a video decoding method, according toan embodiment.

FIG. 19 illustrates a block diagram of a video encoding apparatus,according to an embodiment.

FIG. 20 illustrates a flowchart of a video encoding method, according toan embodiment.

FIG. 21 illustrates an embodiment of modes of left and top neighboringblocks and a mode set of a current block.

FIG. 22 illustrates an embodiment of intra prediction mode directions.

FIG. 23 illustrates an embodiment of an additional mode set.

FIG. 24 illustrates an embodiment of intra prediction mode signalingsyntax.

BEST MODE

According to an embodiment of the present disclosure, a video decodingmethod includes configuring an additional mode set based on mostprobable mode (MPM) modes of a current block; determining an intraprediction mode of the current block, based on the MPM modes and theadditional mode set; and performing intra prediction on the currentblock, based on the intra prediction mode.

According to an embodiment, the MPM modes of the current block mayinclude a prediction mode of a neighboring block adjacent to a left sideof the current block and a prediction mode of a neighboring blockadjacent to a top side of the current block.

According to an embodiment, a neighboring block adjacent to a right sideof the current block and a neighboring block adjacent to a top side ofthe current block may be reconstructed before the current block, and theMPM modes of the current block may include a prediction mode of theneighboring block adjacent to the right side of the current block and aprediction mode of the neighboring block adjacent to the top side of thecurrent block.

According to an embodiment, the additional mode set may be determinedbased on types of the MPM modes.

According to an embodiment, the additional mode set may include at leastone of a DC mode, a planar mode, a vertical mode, a horizontal mode, anda diagonal mode.

According to an embodiment, when the MPM modes are all angular modes,the additional mode set may include at least one of the DC mode, theplanar mode, and intra prediction modes having index increased by n fromindex of each of the MPM modes, wherein n is a non-zero integer.

According to an embodiment, when the MPM modes are all angular modes,the additional mode set may include at least one of a DC mode, a planarmode, intra prediction modes having an index increased by 1 from indexof each of the MPM modes, intra prediction modes having an indexdecreased by 1 from the index of each of the MPM modes, and intraprediction modes having an index decreased by 2 from the index of eachof the MPM modes.

According to an embodiment, when an intra prediction mode of theneighboring block adjacent to the left side of the current block and anintra prediction mode of the neighboring block adjacent to the top sideof the current block are equal and angular modes, the MPM modes and theadditional mode set may include the intra prediction mode of theneighboring block adjacent to the left side, a DC mode, a planar mode, amode of increasing, by 1, an index of the intra prediction mode of theneighboring block adjacent to the left side, an intra prediction modehaving an index decreased by 1 from the index of the intra predictionmode of the neighboring block adjacent to the left side, and an intraprediction mode having an index decreased by 2 from the index of theintra prediction mode of the neighboring block adjacent to the leftside.

According to an embodiment, when a first MPM mode of the MPM modes is anon-angular mode, and a second MPM mode of the MPM modes is an angularmode, the additional mode set may include at least one of a modedifferent from the first MPM mode from among a DC mode and a planarmode, an intra prediction mode having an index increased by n from anindex of the second MPM mode, a vertical mode, and a horizontal mode,wherein n is a non-zero integer.

According to an embodiment of the present disclosure, a video encodingmethod includes configuring an additional mode set based on MPM modes ofa current block; determining an intra prediction mode of the currentblock, based on the MPM modes and the additional mode set; andperforming intra prediction on the current block, based on the intraprediction mode.

According to an embodiment of the present disclosure, a video decodingapparatus includes a memory; and at least one processor connected withthe memory, wherein the at least one processor is configured toconfigure an additional mode set based on MPM modes of a current block,determine an intra prediction mode of the current block, based on theMPM modes and the additional mode set, and perform intra prediction onthe current block, based on the intra prediction mode.

According to an embodiment of the present disclosure, a video encodingapparatus includes a memory; and at least one processor connected withthe memory, wherein the at least one processor is configured toconfigure an additional mode set based on MPM modes of a current block,determine an intra prediction mode of the current block, based on theMPM modes and the additional mode set, and perform intra prediction onthe current block, based on the intra prediction mode.

MODE OF DISCLOSURE

Advantages and features of embodiments and methods of accomplishing thesame may be understood more readily by reference to the embodiments andthe accompanying drawings. In this regard, the disclosure may havedifferent forms and should not be construed as being limited to theembodiments set forth herein. Rather, these embodiments are provided sothat this disclosure will be thorough and complete and will fully conveythe concept of the disclosure to one of ordinary skill in the art.

The terms used in the specification will be briefly defined, and theembodiments will be described in detail.

All terms including descriptive or technical terms which are used in thespecification should be construed as having meanings that are obvious toone of ordinary skill in the art. However, the terms may have differentmeanings according to the intention of one of ordinary skill in the art,precedent cases, or the appearance of new technologies. Also, some termsmay be arbitrarily selected by the applicant, and in this case, themeaning of the selected terms will be described in detail in thedetailed description of the disclosure. Therefore, the terms used in thedisclosure should not be interpreted based on only their names but haveto be defined based on the meaning of the terms together with thedescriptions throughout the specification.

In the following specification, the singular forms include plural formsunless the context clearly indicates otherwise.

When a part “includes” or “comprises” an element, unless there is aparticular description contrary thereto, the part may further includeother elements, not excluding the other elements.

In the following description, terms such as “unit” indicate a softwareor hardware component and the “unit” performs certain functions.However, the “unit” is not limited to software or hardware. The “unit”may be formed so as to be in an addressable storage medium, or may beformed so as to operate one or more processors. Thus, for example, theterm “unit” may refer to components such as software components,object-oriented software components, class components, and taskcomponents, and may include processes, functions, attributes,procedures, subroutines, segments of program code, drivers, firmware,micro codes, circuits, data, a database, data structures, tables,arrays, or variables. A function provided by the components and “units”may be associated with the smaller number of components and “units”, ormay be divided into additional components and “units”.

According to an embodiment of the disclosure, the “unit” may include aprocessor and a memory. The term “processor” should be interpretedbroadly to include a general purpose processor, a central processingunit (CPU), a microprocessor, a digital signal processor (DSP), acontroller, a microcontroller, a state machine, and the like. In someenvironments, the “processor” may refer to an application specificsemiconductor (ASIC), a programmable logic device (PLD), a fieldprogrammable gate array (FPGA), or the like. The term “processor” mayrefer to a combination of processing devices such as, for example, acombination of a DSP and a microprocessor, a combination of a pluralityof microprocessors, a combination of one or more microprocessors inconjunction with a DSP core, or a combination of any other suchconfigurations.

The term “memory” should be interpreted broadly to include anyelectronic component capable of storing electronic information. The term“memory” may refer to various types of processor-readable media, such asa random access memory (RAM), a read-only memory (ROM), a non-volatilerandom access memory (NVRAM), a programmable read-only memory (PROM), anerase-programmable read-only memory (EPROM), an electrically erasablePROM (EEPROM), a flash memory, a magnetic or optical data storagedevice, registers, and the like. When the processor can read informationfrom a memory and/or write information to the memory, the memory is saidto be in an electronic communication state with the processor. Thememory integrated in the processor is in an electronic communicationstate with the processor.

Hereinafter, an “image” may be a static image such as a still image of avideo or may be a dynamic image such as a moving image, that is, thevideo itself.

Hereinafter, a “sample” denotes data assigned to a sampling position ofan image, i.e., data to be processed. For example, pixel values of animage in a spatial domain and transform coefficients on a transformdomain may be samples A unit including at least one such sample may bedefined as a block.

Hereinafter, the disclosure will now be described more fully withreference to the accompanying drawings for one of ordinary skill in theart to be able to perform the embodiments without any difficulty. Inaddition, portions irrelevant to the description will be omitted in thedrawings for a clear description of the disclosure.

Hereinafter, an image encoding apparatus and an image decodingapparatus, and an image encoding method and an image decoding methodaccording to embodiments will be described with reference to FIGS. 1through 16. With reference to FIGS. 3 to 16, a method of determining adata unit of an image according to an embodiment will be described, andwith reference to FIGS. 17 to 24, a method of configuring an additionalmode set based on most probable mode (MPM) modes of a current block,determining an intra prediction mode of the current block based on theMPM modes and the additional mode set, and performing intra predictionon the current block, based on the determined intra prediction modeaccording to an embodiment will be described.

Hereinafter, the method and apparatus for adaptively selecting a contextmodel, based on various shapes of coding unit according to an embodimentof the disclosure will now be described with reference to FIGS. 1 and 2.

FIG. 1 is a schematic block diagram of an image decoding apparatus 100,according to an embodiment.

The image decoding apparatus 100 may include a receiver 110 and adecoder 120. The receiver 110 and the decoder 120 may include at leastone processor. Also, the receiver 110 and the decoder 120 may include amemory storing instructions to be performed by the at least oneprocessor.

The receiver 110 may receive a bitstream. The bitstream includesinformation of an image encoded by an image encoding apparatus 2200described later. Also, the bitstream may be transmitted from the imageencoding apparatus 2200. The image encoding apparatus 2200 and the imagedecoding apparatus 100 may be connected via wire or wirelessly, and thereceiver 110 may receive the bitstream via wire or wirelessly. Thereceiver 110 may receive the bitstream from a storage medium, such as anoptical medium or a hard disk. The decoder 120 may reconstruct an imagebased on information obtained from the received bitstream. The decoder120 may obtain, from the bitstream, a syntax element for reconstructingthe image. The decoder 120 may reconstruct the image based on the syntaxelement.

Operations of the image decoding apparatus 100 will be described indetail with reference to FIG. 2.

FIG. 2 is a flowchart of an image decoding method, according to anembodiment.

According to an embodiment of the disclosure, the receiver 110 receivesa bitstream.

The image decoding apparatus 100 obtains, from a bitstream, a bin stringcorresponding to a split shape mode of a coding unit (operation 210).The image decoding apparatus 100 determines a split rule of the codingunit (operation 220). Also, the image decoding apparatus 100 splits thecoding unit into a plurality of coding units, based on at least one ofthe split rule and the bin string corresponding to the split shape mode(operation 230). The image decoding apparatus 100 may determine anallowable first range of a size of the coding unit, according to a ratioof the width to the height of the coding unit, so as to determine thesplit rule. The image decoding apparatus 100 may determine an allowablesecond range of the size of the coding unit, according to the splitshape mode of the coding unit, so as to determine the split rule.

Hereinafter, splitting of a coding unit will be described in detailaccording to an embodiment of the disclosure.

First, one picture may be split into one or more slices. One slice maybe a sequence of largest coding units (coding tree units (CTUs)). Thereis a largest coding block (coding tree block (CTB)) conceptuallycompared to a largest coding unit (CTU).

A largest coding block (CTB) refers to an N×N block including N×Nsamples (N is an integer). Each color component may be split into one ormore largest coding blocks.

When a picture has three sample arrays (sample arrays for Y, Cr, and Cbcomponents), a largest coding unit (CTU) includes a largest coding blockof a luma sample, two corresponding largest coding blocks of chromasamples, and syntax structures used to encode the lama sample and thechroma samples. When a picture is a monochrome picture, a largest codingunit includes a largest coding block of a monochrome sample and syntaxstructures used to encode the monochrome samples. When a picture is apicture having color planes separated according to color components, alargest coding unit includes syntax structures used to encode thepicture and samples of the picture.

One largest coding block (CTB) may be split into M×N coding blocksincluding M×N samples (M and N are integers).

When a picture has sample arrays for Y, Cr, and Cb components, a codingunit (CU) includes a coding block of a luma sample, two correspondingcoding blocks of chroma samples, and syntax structures used to encodethe luma sample and the chroma samples. When a picture is a monochromepicture, a coding unit includes a coding block of a monochrome sampleand syntax structures used to encode the monochrome samples. When apicture is a picture having color planes separated according to colorcomponents, a coding unit includes syntax structures used to encode thepicture and samples of the picture.

As described above, a largest coding block and a largest coding unit areconceptually distinguished from each other, and a coding block and acoding unit are conceptually distinguished from each other. That is, a(largest) coding unit refers to a data structure including a (largest)coding block including a corresponding sample and a syntax structurecorresponding to the (largest) coding block. However, because it isunderstood by one of ordinary skill in the art that a (largest) codingunit or a (largest) coding block refers to a block of a preset sizeincluding a preset number of samples, a largest coding block and alargest coding unit, or a coding block and a coding unit are mentionedin the following specification without being distinguished unlessotherwise described.

An image may be split into largest coding units (CTUs). A size of eachlargest coding unit may be determined based on information obtained froma bitstream. A shape of each largest coding unit may be a square shapeof the same size. However, the disclosure is not limited thereto.

For example, information about a maximum size of a luma coding block maybe obtained from a bitstream. For example, the maximum size of the lumacoding block indicated by the information about the maximum size of theluma coding block may be one of 4×4, 8×8, 16×16, 32×32, 64×64, 128×128,and 256×256.

For example, information about a luma block size difference andinformation about a maximum size of a luma coding block that isbi-splittable may be obtained from a bitstream. The information aboutthe luma block size difference may refer to a size difference between aluma largest coding unit and a largest luma coding block that isbi-splittable. Accordingly, when the information about the maximum sizeof the luma coding block that is bi-splittable and the information aboutthe luma block size difference obtained from the bitstream are combinedwith each other, a size of the luma largest coding unit may bedetermined. A size of a chroma largest coding unit may be determined byusing the size of the luma largest coding unit. For example, when aY:Cb:Cr ratio is 4:2:0 according to a color format, a size of a chromablock may be half a size of a luma block, and a size of a chroma largestcoding unit may be half the size of the luma largest coding unit.

According to an embodiment, because the information about the maximumsize of the luma coding block that is bi-splittable is obtained from thebitstream, the maximum size of the luma coding block that isbi-splittable may be variably determined. In contrast, a maximum size ofa luma coding block that is ternary splittable may be fixed. Forexample, the maximum size of the luma coding block that is ternarysplittable in an I-slice may be 32×32, and the maximum size of the lumacoding block that is ternary splittable in a P-slice or a B-slice may be64×64.

Also, a largest coding unit may be hierarchically split into codingunits based on split shape mode information obtained from a bitstream.At least one of information indicating whether quad splitting isperformed, information indicating whether multi-splitting is performed,split direction information, and split type information may be obtainedas the split shape mode information from the bitstream.

For example, the information indicating whether quad splitting isperformed may indicate whether a current coding unit is quad split(QUAD_SPLIT) or not.

When the current coding unit is not quad split, the informationindicating whether multi-splitting is performed may indicate whether thecurrent coding unit is no longer split (NO_SPLIT) or binary/ternarysplit.

When the current coding unit is binary split or ternary split, the splitdirection information indicates that the current coding unit is split inone of a horizontal direction and a vertical direction.

When the current coding unit is split in the horizontal direction or thevertical direction, the split type information indicates that thecurrent coding unit is binary split or ternary split.

A split mode of the current coding unit may be determined according tothe split direction information and the split type information. A splitmode when the current coding unit is binary split in the horizontaldirection may be determined to be a binary horizontal split mode(SPLIT_BT_HOR), a split mode when the current coding unit is ternarysplit in the horizontal direction may be determined to be a ternaryhorizontal split mode (SPLIT_TT_HOR), a split mode when the currentcoding unit is binary split in the vertical direction may be determinedto be a binary vertical split mode (SPLIT_BTVER), and a split mode whenthe current coding unit is ternary split in the vertical direction maybe determined to be a ternary vertical split mode (SPLIT_TT_VER)

The image decoding apparatus 100 may obtain split shape mode informationfrom a bitstream from one bin string. The bitstream received by theimage decoding apparatus 100 may include a fixed length binary code, aunary code, a truncated unary code, a pre-determined binary code, etc.The bin string is a binary sequence of information. The bin string mayinclude at least one bit. The image decoding apparatus 100 may obtainthe split shape mode information corresponding to the bin string basedon a split rule. The image decoding apparatus 100 may determine whetheror not to quad split a coding unit, a split direction, and a split type,based on one bin string.

A coding unit may be equal to or smaller than a largest coding unit. Forexample, because a largest coding unit is a coding unit having a maximumsize, the largest coding unit is one of coding units. When split shapemode information about a largest coding unit indicates that splitting isnot performed, a coding unit determined in the largest coding unit hasthe same size as that of the largest coding unit. When split shape codeinformation about a largest coding unit indicates that splitting is tobe performed, the largest coding unit may be split into coding units.Also, when split shape mode information about a coding unit indicatesthat splitting is to be performed, the coding unit may be split intosmaller coding units. However, splitting of an image is not limitedthereto, and a largest coding unit and a coding unit may not bedistinguished from each other. Splitting of a coding unit will bedescribed in more detail with reference to FIGS. 3 through 16.

Also, one or more prediction blocks for prediction may be determinedfrom a coding unit. A prediction block may be equal to or smaller than acoding unit. Also, one or more transform blocks for transform may bedetermined from a coding unit. A transform block may be equal to orsmaller than a coding unit.

Shapes and sizes of a transform block and a prediction block may not berelated to each other.

In another embodiment, prediction may be performed by using a codingunit as a prediction unit. Also, transformation may be performed byusing a coding unit as a transform block.

Splitting of a coding unit will be described in detail with reference toFIGS. 3 to 16. Each of a current block and a neighboring block of thepresent disclosure may indicate one of a largest coding unit, a codingunit, a prediction block, and a transform block. Also, a current blockor a current coding unit is a block on which decoding or encoding iscurrently performed or a block on which splitting is currentlyperformed. A neighboring block may be a block that is reconstructedbefore a current block. The neighboring block may be spatially ortemporally adjacent to the current block. The neighboring block may belocated at one of a lower-left side, a left side, an upper-left side, anupper side, an upper-right side, a right side, and a lower-right side ofthe current block.

FIG. 3 illustrates a process, performed by the image decoding apparatus100, of determining at least one coding unit by splitting a currentcoding unit, according to an embodiment.

A block shape may include 4N×4N, 4N×2N, 2N×4N, 4N×N, N×4N, 32N×N, N×32N,16N×N, N×16N, 8N×N or N×8N. In this regard, N may be a positive integer.Block shape information is information indicating at least one of ashape, a direction, a ratio of a width to a height, or a size of acoding unit.

The shape of the coding unit may include a square shape and a non-squareshape. When the width and the height of the coding unit are the same(i.e., when the block shape of the coding unit is 4N×4N), the imagedecoding apparatus 100 may determine the block shape information of thecoding unit as a square shape. The image decoding apparatus 100 maydetermine the shape of the coding unit as a non-square shape.

When the width and the height of the coding unit are different from eachother (i.e., when the block shape of the coding unit is 4N×2N, 2N×4N,4N×N, N×4N, 32N×N, N×32N, 16N×N, N×16N, 8N×N or N×8N), the imagedecoding apparatus 100 may determine the block shape information of thecoding unit as a non-square shape. When the shape of the coding unit isa non-square shape, the image decoding apparatus 100 may determine theratio of the width to the height in the block shape information of thecoding unit as at least one of 1:2, 2:1, 1:4, 4:1, 1:8, 8:1, 1:16, 16:1,1:32, and 32:1. Also, the image decoding apparatus 100 may determinewhether the coding unit is in a horizontal direction or a verticaldirection, based on a length of the width and a length of the height ofthe coding unit. Also, the image decoding apparatus 100 may determinethe size of the coding unit based on at least one of the length of thewidth, the length of the height, or an area, which is of the codingunit.

According to an embodiment, the image decoding apparatus 100 maydetermine a shape of the coding unit by using the block shapeinformation, and may determine which shape the coding unit is split intoby using split shape mode information. That is, a coding unit splittingmethod indicated by the split shape mode information may be determinedaccording to which block shape is indicated by the block shapeinformation used by the image decoding apparatus 100.

The image decoding apparatus 100 may determine the split shape modeinformation from a bitstream. However, the present disclosure is notlimited thereto, and the image decoding apparatus 100 and the imageencoding apparatus 200 may determine the split shape mode informationthat is predetermined based on the block shape information. The imagedecoding apparatus 100 may determine the split shape mode informationthat is predetermined for a largest coding unit or a smallest codingunit. For example, the image decoding apparatus 100 may determine thatsplit shape mode information of a largest coding unit indicatesquad-split. Also, the image decoding apparatus 100 may determine thatsplit shape mode information of a smallest coding unit indicates “not toperform splitting”. For example, the image decoding apparatus 100 maydetermine a size of the largest coding unit to be 256×256. The imagedecoding apparatus 100 may determine that the predetermined split shapemode information indicates quad-split. The quad-split is a split shapemode in which a width and a height of a coding unit are halved. Theimage decoding apparatus 100 may obtain a coding unit having a size of128×128 from the largest coding unit having a size of 256×256, based onthe split shape mode information. Also, the image decoding apparatus 100may determine a size of the smallest coding unit to be 4×4. The imagedecoding apparatus 100 may obtain the split shape mode informationindicating “not to perform splitting” for the smallest coding unit.

According to an embodiment, the image decoding apparatus 100 may use theblock shape information indicating that the current coding unit has asquare shape. For example, the image decoding apparatus 100 maydetermine whether not to split a square coding unit, whether tovertically split the square coding unit, whether to horizontally splitthe square coding unit, or whether to split the square coding unit intofour coding units, based on the split shape mode information. Referringto FIG. 3, when the block shape information of a current coding unit 300indicates a square shape, the decoder 120 may determine that a codingunit 310 a having the same size as the current coding unit 300 is not tobe split, based on the split shape mode information indicating not toperform splitting, or may determine coding units 310 b, 310 c, 310 d,310 e, and 310 f split based on the split shape mode informationindicating a preset splitting method.

Referring to FIG. 3, according to an embodiment, the image decodingapparatus 100 may determine two coding units 310 b obtained byvertically splitting the current coding unit 300, based on the splitshape mode information indicating to vertically perform splitting. Theimage decoding apparatus 100 may determine two coding units 310 cobtained by horizontally splitting the current coding unit 300, based onthe split shape mode information indicating to horizontally performsplitting. The image decoding apparatus 100 may determine four codingunits 310 d obtained by vertically and horizontally splitting thecurrent coding unit 300, based on the split shape mode informationindicating to vertically and horizontally perform splitting. The imagedecoding apparatus 100 may determine three coding units 310 e obtainedby vertically splitting the current coding unit 300, based on the splitshape mode information indicating to vertically perform ternarysplitting according to an embodiment. The image decoding apparatus 100may determine three coding units 310 f obtained by horizontallysplitting the current coding unit 300, based on the split shape modeinformation indicating to horizontally perform ternary splitting.However, split shapes by which the square coding unit is splittable arenot limited to the aforementioned split shapes, and the split shape modeinformation may include various shapes. Preset split shapes by which thesquare coding unit is split will now be described in detail throughvarious embodiments.

FIG. 4 illustrates a process, performed by the image decoding apparatus100, of determining at least one coding unit by splitting a non-squarecoding unit, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 may useblock shape information indicating that a current coding unit has anon-square shape. The image decoding apparatus 100 may determine,according to split shape mode information, whether not to split thenon-square current coding unit or whether to split the non-squarecurrent coding unit by using a preset method. Referring to FIG. 4, whenthe block shape information of a current coding unit 400 or 450indicates a non-square shape, the image decoding apparatus 100 maydetermine a coding unit 410 or 460 having the same size as the currentcoding unit 400 or 450 based on the split shape mode informationindicating not to perform splitting, or determine coding units 420 a and420 b, 430 a to 430 c, 470 a and 470 b, or 480 a to 480 c split based onthe split shape mode information indicating a preset splitting method.Preset splitting methods of splitting a non-square coding unit will nowbe described in detail through various embodiments.

According to an embodiment, the image decoding apparatus 100 maydetermine, by using the split shape mode information, a split shape bywhich a coding unit is to be split, and in this case, the split shapemode information may indicate the number of one or more coding units tobe generated by splitting the coding unit. Referring to FIG. 4, when thesplit shape mode information indicates to split the current coding unit400 or 450 into two coding units, the image decoding apparatus 100 maydetermine two coding units 420 a and 420 b, or 470 a and 470 b includedin the current coding unit 400 or 450 by splitting the current codingunit 400 or 450 based on the split shape mode information.

According to an embodiment, when the image decoding apparatus 100 splitsthe non-square current coding unit 400 or 450 based on the split shapemode information, the image decoding apparatus 100 may split the currentcoding unit 400 or 450, in consideration of the location of a long sideof the non-square current coding unit 400 or 450. For example, the imagedecoding apparatus 100 may determine a plurality of coding units bysplitting the long side of the current coding unit 400 or 450, inconsideration of the shape of the current coding unit 400 or 450.

According to an embodiment, when the split shape mode informationindicates to split (ternary split) a coding unit into an odd number ofblocks, the image decoding apparatus 100 may determine an odd number ofcoding units included in the current coding unit 400 or 450. Forexample, when the split shape mode information indicates to split thecurrent coding unit 400 or 450 into three coding units, the imagedecoding apparatus 100 may split the current coding unit 400 or 450 intothree coding units 430 a, 430 b, and 430 c, or 480 a, 480 b, and 480 c.

According to an embodiment, a ratio of a width to a height of thecurrent coding unit 400 or 450 may be 4:1 or 1:4. When the ratio of thewidth to the height is 4:1, a length of the width is greater than alength of the height, and thus the block shape information may indicatea horizontal direction. When the ratio of the width to the height is1:4, a length of the width is smaller than a length of the height, andthus the block shape information may indicate a vertical direction. Theimage decoding apparatus 100 may determine to split the current codingunit into an odd number of blocks, based on the split shape modeinformation. Also, the image decoding apparatus 100 may determine asplit direction of the current coding unit 400 or 450, based on theblock shape information of the current coding unit 400 or 450. Forexample, when the current coding unit 400 is in a vertical direction,the image decoding apparatus 100 may horizontally split the currentcoding unit 400 and may determine the coding units 430 a, 430 b, and 430c. Also, when the current coding unit 450 is in a horizontal direction,the image decoding apparatus 100 may vertically split the current codingunit 450 and may determine the coding units 480 a, 480 b, and 480 c.

According to an embodiment, the image decoding apparatus 100 maydetermine an odd number of coding units included in the current codingunit 400 or 450, and sizes of all of the determined coding units may notbe the same. For example, a preset coding unit 430 b or 480 b from amongthe determined odd number of coding units 430 a, 430 b, and 430 c, or480 a, 480 b, and 480 c may have a size different from sizes of theother coding units 430 a and 430 c, or 480 a and 480 c. That is, codingunits which may be determined by splitting the current coding unit 400or 450 may have multiple sizes and, in some cases, all of the odd numberof coding units 430 a, 430 b, and 430 c, or 480 a, 480 b, and 480 c mayhave different sizes.

According to an embodiment, when the split shape mode informationindicates to split a coding unit into an odd number of blocks, the imagedecoding apparatus 100 may determine an odd number of coding unitsincluded in the current coding unit 400 or 450, and may put a presetrestriction on at least one coding unit from among the odd number ofcoding units generated by splitting the current coding unit 400 or 450.Referring to FIG. 4, the image decoding apparatus 100 may allow adecoding method of the coding unit 430 b or 480 b to be different fromthat of the other coding units 430 a and 430 c, or 480 a and 480 c,wherein the coding unit 430 b or 480 b is at a center location fromamong the three coding units 430 a, 430 b, and 430 c, or 480 a, 480 b,and 480 c generated by splitting the current coding unit 400 or 450. Forexample, the image decoding apparatus 100 may restrict the coding unit430 b or 480 b at the center location to be no longer split or to besplit only a preset number of times, unlike the other coding units 430 aand 430 c, or 480 a and 480 c.

FIG. 5 illustrates a process, performed by the image decoding apparatus100, of splitting a coding unit based on at least one of block shapeinformation and split shape mode information, according to anembodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine to split or not to split a square first coding unit 500 intocoding units, based on at least one of the block shape information andthe split shape mode information. According to an embodiment, when thesplit shape mode information indicates to split the first coding unit500 in a horizontal direction, the image decoding apparatus 100 maydetermine a second coding unit 510 by splitting the first coding unit500 in a horizontal direction. A first coding unit, a second codingunit, and a third coding unit used according to an embodiment are termsused to understand a relation before and after a coding unit is split.For example, the second coding unit may be determined by splitting thefirst coding unit, and the third coding unit may be determined bysplitting the second coding unit. Hereinafter, it will be understoodthat a relationship among the first coding unit, the second coding unit,and the third coding unit applies to the following descriptions.

According to an embodiment, the image decoding apparatus 100 maydetermine to split or not to split the determined second coding unit 510into coding units, based on the split shape mode information. Referringto FIG. 5, the image decoding apparatus 100 may split the non-squaresecond coding unit 510, which is determined by splitting the firstcoding unit 500, into one or more third coding units 520 a, or 520 b,520 c, and 520 d based on the split shape mode information, or may notsplit the non-square second coding unit 510. The image decodingapparatus 100 may obtain the split shape mode information, and may splita plurality of various-shaped second coding units (e.g., 510) bysplitting the first coding unit 500, based on the obtained split shapemode information, and the second coding unit 510 may be split by using asplitting method of the first coding unit 500, based on the split shapemode information. According to an embodiment, when the first coding unit500 is split into the second coding units 510 based on the split shapemode information of the first coding unit 500, the second coding unit510 may also be split into the third coding units 520 a, or 520 b, 520c, and 520 d, based on the split shape mode information of the secondcoding unit 510. That is, a coding unit may be recursively split basedon the split shape mode information of each coding unit. Therefore, asquare coding unit may be determined by splitting a non-square codingunit, and a non-square coding unit may be determined by recursivelysplitting the square coding unit.

Referring to FIG. 5, a preset coding unit (e.g., a coding unit locatedat a center location or a square coding unit) from among an odd numberof third coding units 520 b, 520 c, and 520 d determined by splittingthe non-square second coding unit 510 may be recursively split.According to an embodiment, the square third coding unit 520 b fromamong the odd number of third coding units 520 b, 520 c, and 520 d maybe split in a horizontal direction into a plurality of fourth codingunits. A non-square fourth coding unit 530 b or 530 d from among theplurality of fourth coding units 530 a, 530 b, 530 c, and 530 d may besplit again into a plurality of coding units. For example, thenon-square fourth coding unit 530 b or 530 d may be split again into anodd number of coding units. A method that may be used to recursivelysplit a coding unit will be described below through various embodiments.

According to an embodiment, the image decoding apparatus 100 may spliteach of the third coding units 520 a, or 520 b, 520 c, and 520 d intocoding units, based on the split shape mode information. Also, the imagedecoding apparatus 100 may determine not to split the second coding unit510, based on the split shape mode information. According to anembodiment, the image decoding apparatus 100 may split the non-squaresecond coding unit 510 into the odd number of third coding units 520 b,520 c, and 520 d. The image decoding apparatus 100 may put a presetrestriction on a preset third coding unit from among the odd number ofthird coding units 520 b, 520 c, and 520 d. For example, the imagedecoding apparatus 100 may restrict the third coding unit 520 c at acenter location from among the odd number of third coding units 520 b,520 c, and 520 d to be no longer split or to be split a settable numberof times.

Referring to FIG. 5, the image decoding apparatus 100 may restrict thethird coding unit 520 c, which is at the center location from among theodd number of third coding units 520 b, 520 c, and 520 d included in thenon-square second coding unit 510, to be no longer split, to be split byusing a preset splitting method (e.g., split into only four coding unitsor split by using a splitting method of the second coding unit 510), orto be split only a preset number of times (e.g., split only n times(where n>0)). However, the restrictions on the third coding unit 520 cat the center location are not limited to the aforementioned examples,and it should be interpreted that the restrictions may include variousrestrictions for decoding the third coding unit 520 c at the centerlocation differently from the other third coding units 520 b and 520 d.

According to an embodiment, the image decoding apparatus 100 may obtainthe split shape mode information, which is used to split a currentcoding unit, from a preset location in the current coding unit.

FIG. 6 illustrates a method, performed by the image decoding apparatus100, of determining a preset coding unit from among an odd number ofcoding units, according to an embodiment.

Referring to FIG. 6, split shape mode information of a current codingunit 600 or 650 may be obtained from a sample of a preset location(e.g., a sample 640 or 690 of a center location) from among a pluralityof samples included in the current coding unit 600 or 650. However, thepreset location in the current coding unit 600, from which at least oneof the split shape mode information may be obtained, is not limited tothe center location in FIG. 6, and it should be interpreted that thepreset location may include various locations (e.g., top, bottom, left,right, upper-left, lower-left, upper-right, lower-right locations, orthe like) included in the current coding unit 600. The image decodingapparatus 100 may obtain the split shape mode information from thepreset location and may determine to split or not to split the currentcoding unit into various-shaped and various-sized coding units.

According to an embodiment, when the current coding unit is split into apreset number of coding units, the image decoding apparatus 100 mayselect one of the coding units. Various methods that may be used toselect one of a plurality of coding units will be described belowthrough various embodiments.

According to an embodiment, the image decoding apparatus 100 may splitthe current coding unit into a plurality of coding units, and maydetermine a coding unit at a preset location.

According to an embodiment, the image decoding apparatus 100 may useinformation indicating locations of an odd number of coding units so asto determine a coding unit at a center location from among the oddnumber of coding units. Referring to FIG. 6, the image decodingapparatus 100 may determine an odd number of coding units 620 a, 620 b,and 620 c or an odd number of coding units 660 a, 660 b, and 660 c bysplitting the current coding unit 600 or the current coding unit 650.The image decoding apparatus 100 may determine the coding unit 620 b ata center location or the coding unit 660 b at a center location by usinginformation about locations of the odd number of coding units 620 a, 620b, and 620 c or the odd number of coding units 660 a, 660 b, and 660 c.For example, the image decoding apparatus 100 may determine the codingunit 620 b of the center location by determining the locations of thecoding units 620 a, 620 b, and 620 c based on information indicatinglocations of preset samples included in the coding units 620 a, 620 b,and 620 c. In detail, the image decoding apparatus 100 may determine thecoding unit 620 b at the center location by determining the locations ofthe coding units 620 a, 620 b, and 620 c based on information indicatinglocations of top-left samples 630 a, 630 b, and 630 c of the codingunits 620 a, 620 b, and 620 c.

According to an embodiment, the information indicating the locations ofthe top-left samples 630 a, 630 b, and 630 c, which are included in thecoding units 620 a, 620 b, and 620 c, respectively, may includeinformation about locations or coordinates of the coding units 620 a,620 b, and 620 c in a picture. According to an embodiment, theinformation indicating the locations of the top-left samples 630 a, 630b, and 630 c, which are included in the coding units 620 a, 620 b, and620 c, respectively, may include information indicating widths orheights of the coding units 620 a, 620 b, and 620 c included in thecurrent coding unit 600, and the widths or heights may correspond toinformation indicating differences between the coordinates of the codingunits 620 a, 620 b, and 620 c in the picture. That is, the imagedecoding apparatus 100 may determine the coding unit 620 b at the centerlocation by directly using the information about the locations orcoordinates of the coding units 620 a, 620 b, and 620 c in the picture,or by using the information about the widths or heights of the codingunits, which correspond to the difference values between thecoordinates.

According to an embodiment, information indicating the location of thetop-left sample 630 a of the upper coding unit 620 a may includecoordinates (xa, ya), information indicating the location of thetop-left sample 530 b of the middle coding unit 620 b may includecoordinates (xb, yb), and information indicating the location of thetop-left sample 630 c of the lower coding unit 620 c may includecoordinates (xc, yc). The image decoding apparatus 100 may determine themiddle coding unit 620 b by using the coordinates of the top-leftsamples 630 a, 630 b, and 630 c which are included in the coding units620 a, 620 b, and 620 c, respectively. For example, when the coordinatesof the top-left samples 630 a, 630 b, and 630 c are sorted in anascending or descending order, the coding unit 620 b including thecoordinates (xb, yb) of the sample 630 b at a center location may bedetermined as a coding unit at a center location from among the codingunits 620 a, 620 b, and 620 c determined by splitting the current codingunit 600. However, the coordinates indicating the locations of thetop-left samples 630 a, 630 b, and 630 c may include coordinatesindicating absolute locations in the picture, or may use coordinates(dxb, dyb) indicating a relative location of the top-left sample 630 bof the middle coding unit 620 b and coordinates (dxc, dyc) indicating arelative location of the top-left sample 630 c of the lower coding unit620 c, with reference to the location of the top-left sample 630 a ofthe upper coding unit 620 a. Also, a method of determining a coding unitat a preset location by using coordinates of a sample included in thecoding unit as information indicating a location of the sample is notlimited to the above-described method, and may include variousarithmetic methods capable of using the coordinates of the sample.

According to an embodiment, the image decoding apparatus 100 may splitthe current coding unit 600 into the plurality of coding units 620 a,620 b, and 620 c, and may select one of the coding units 620 a, 620 b,and 620 c, based on a preset criterion. For example, the image decodingapparatus 100 may select the coding unit 620 b, which has a sizedifferent from that of the others, from among the coding units 620 a,620 b, and 620 c.

According to an embodiment, the image decoding apparatus 100 maydetermine the widths or heights of the coding units 620 a, 620 b, and620 c by using the coordinates (xa, ya) indicating the location of thetop-left sample 630 a of the upper coding unit 620 a, the coordinates(xb, yb) indicating the location of the top-left sample 630 b of themiddle coding unit 620 b, and the coordinates (xc, yc) indicating thelocation of the top-left sample 630 c of the lower coding unit 620 c.The image decoding apparatus 100 may determine the respective sizes ofthe coding units 620 a, 620 b, and 620 c by using the coordinates (xa,ya), (xb, yb), and (xc, yc) indicating the locations of the coding units620 a, 620 b, and 620 c. According to an embodiment, the image decodingapparatus 100 may determine the width of the upper coding unit 620 a tobe a width of the current coding unit 600. The image decoding apparatus100 may determine the height of the upper coding unit 620 a to be yb-ya.According to an embodiment, the image decoding apparatus 100 maydetermine the width of the middle coding unit 620 b to be a width of thecurrent coding unit 600. The image decoding apparatus 100 may determinethe height of the middle coding unit 620 b to be yc-yb. According to anembodiment, the image decoding apparatus 100 may determine the width orheight of the lower coding unit 620 c by using the width or height ofthe current coding unit 600 and the widths or heights of the upper andmiddle coding units 620 a and 620 b. The image decoding apparatus 100may determine a coding unit, which has a size different from that of theothers, based on the determined widths and heights of the coding units620 a to 620 c. Referring to FIG. 6, the image decoding apparatus 100may determine the middle coding unit 620 b, which has a size differentfrom the size of the upper and lower coding units 620 a and 620 c, asthe coding unit of the preset location. However, the above-describedmethod, performed by the image decoding apparatus 100, of determining acoding unit having a size different from the size of the other codingunits merely corresponds to an example of determining a coding unit at apreset location by using the sizes of coding units, which are determinedbased on coordinates of samples, and thus various methods of determininga coding unit at a preset location by comparing the sizes of codingunits, which are determined based on coordinates of preset samples, maybe used.

The image decoding apparatus 100 may determine a width or a height ofeach of the coding units 660 a, 660 b, and 660 c by using coordinates(xd, yd) that are information indicating a location of a top-left sample670 a of the left coding unit 660 a, coordinates (xe, ye) that areinformation indicating a location of a top-left sample 670 b of themiddle coding unit 660 b, and coordinates (xf, yf) that are informationindicating a location of a top-left sample 670 c of the right codingunit 660 c. The image decoding apparatus 100 may determine sizes of thecoding units 660 a, 660 b, and 660 c by using the coordinates (xd, yd),(xe, ye), and (xf, yf) indicating the locations of the coding units 660a, 660 b, and 660 c.

According to an embodiment, the image decoding apparatus 100 maydetermine the width of the left coding unit 660 a to be xe-xd. The imagedecoding apparatus 100 may determine the height of the left coding unit660 a as the height of the current coding unit 650. According to anembodiment, the image decoding apparatus 100 may determine the width ofthe middle coding unit 660 b to be xf-xe. The image decoding apparatus100 may determine the height of the middle coding unit 660 b to be theheight of the current coding unit 600. According to an embodiment, theimage decoding apparatus 100 may determine the width or the height ofthe right coding unit 660 c by using the width or the height of thecurrent coding unit 650 and the width and the height of the left codingunit 660 a and the middle coding unit 660 b. The image decodingapparatus 100 may determine a coding unit, which has a size differentfrom that of the others, based on the determined widths and heights ofthe coding units 660 a, 660 b, and 660 c. Referring to FIG. 6, the imagedecoding apparatus 100 may determine the middle coding unit 660 b, whichhas a size different from the size of the left coding unit 660 a and theright coding unit 660 c, as the coding unit of the preset location.However, the above-described method, performed by the image decodingapparatus 100, of determining a coding unit having a size different fromthe size of the other coding units merely corresponds to an example ofdetermining a coding unit at a preset location by using the sizes ofcoding units, which are determined based on coordinates of samples, andthus various methods of determining a coding unit at a preset locationby comparing the sizes of coding units, which are determined based oncoordinates of preset samples, may be used.

However, locations of samples considered to determine locations ofcoding units are not limited to the above-described top-left locations,and information about arbitrary locations of samples included in thecoding units may be used.

According to an embodiment, the image decoding apparatus 100 may selecta coding unit at a preset location from among an odd number of codingunits determined by splitting the current coding unit, considering theshape of the current coding unit. For example, when the current codingunit has a non-square shape where a width of which is longer than aheight, the image decoding apparatus 100 may determine the coding unitat the preset location in a horizontal direction. That is, the imagedecoding apparatus 100 may determine one of coding units at differentlocations in a horizontal direction and may put a restriction on thecoding unit. When the current coding unit has a non-square shape where aheight of which is longer than a width, the image decoding apparatus 100may determine the coding unit at the preset location in a verticaldirection. That is, the image decoding apparatus 100 may determine oneof coding units at different locations in a vertical direction and mayput a restriction on the coding unit.

According to an embodiment, the image decoding apparatus 100 may useinformation indicating respective locations of an even number of codingunits, to determine the coding unit at the preset location from amongthe even number of coding units. The image decoding apparatus 100 maydetermine an even number of coding units by splitting (binary splitting)the current coding unit, and may determine the coding unit at the presetlocation by using the information about the locations of the even numberof coding units. An operation related thereto may correspond to theoperation of determining a coding unit at a preset location (e.g., acenter location) from among an odd number of coding units, which hasbeen described in detail above with reference to FIG. 6, and thusdetailed descriptions thereof are not provided here.

According to an embodiment, when a non-square current coding unit issplit into a plurality of coding units, preset information about acoding unit at a preset location may be used in a splitting operation todetermine the coding unit at the preset location from among theplurality of coding units. For example, the image decoding apparatus 100may use at least one of block shape information and split shape modeinformation, which is stored in a sample included in a coding unit at acenter location, in a splitting operation to determine the coding unitat the center location from among the plurality of coding unitsdetermined by splitting the current coding unit.

Referring to FIG. 6, the image decoding apparatus 100 may split thecurrent coding unit 600 into the plurality of coding units 620 a, 620 b,and 620 c based on the split shape mode information, and may determinethe coding unit 620 b at a center location from among the plurality ofthe coding units 620 a, 620 b, and 620 c. Furthermore, the imagedecoding apparatus 100 may determine the coding unit 620 b at the centerlocation, in consideration of a location from which the split shape modeinformation is obtained. That is, the split shape mode information ofthe current coding unit 600 may be obtained from the sample 640 at acenter location of the current coding unit 600 and, when the currentcoding unit 600 is split into the plurality of coding units 620 a, 620b, and 620 c based on the split shape mode information, the coding unit620 b including the sample 640 may be determined as the coding unit atthe center location. However, information used to determine the codingunit at the center location is not limited to the split shape modeinformation, and various kinds of information may be used to determinethe coding unit at the center location.

According to an embodiment, preset information for identifying thecoding unit at the preset location may be obtained from a preset sampleincluded in a coding unit to be determined. Referring to FIG. 6, theimage decoding apparatus 100 may use the split shape mode information,which is obtained from a sample at a preset location in the currentcoding unit 600 (e.g., a sample at a center location of the currentcoding unit 600) to determine a coding unit at a preset location fromamong the plurality of the coding units 620 a, 620 b, and 620 cdetermined by splitting the current coding unit 600 (e.g., a coding unitat a center location from among a plurality of split coding units). Thatis, the image decoding apparatus 100 may determine the sample at thepreset location by considering a block shape of the current coding unit600, may determine the coding unit 620 b including a sample, from whichpreset information (e.g., the split shape mode information) may beobtained, from among the plurality of coding units 620 a, 620 b, and 620c determined by splitting the current coding unit 600, and may put apreset restriction on the coding unit 620 b. Referring to FIG. 6,according to an embodiment, the image decoding apparatus 100 maydetermine the sample 640 at the center location of the current codingunit 600 as the sample from which the preset information may beobtained, and may put a preset restriction on the coding unit 620 bincluding the sample 640, in a decoding operation. However, the locationof the sample from which the preset information may be obtained is notlimited to the above-described location, and may include arbitrarylocations of samples included in the coding unit 620 b to be determinedfor a restriction.

According to an embodiment, the location of the sample from which thepreset information is obtainable may be determined based on the shape ofthe current coding unit 600. According to an embodiment, the block shapeinformation may indicate whether the current coding unit has a square ornon-square shape, and the location of the sample from which the presetinformation is obtainable may be determined based on the shape. Forexample, the image decoding apparatus 100 may determine a sample locatedon a boundary for dividing at least one of a width and height of thecurrent coding unit in half, as the sample from which the presetinformation is obtainable, by using at least one of information aboutthe width of the current coding unit and information about the height ofthe current coding unit. As another example, when the block shapeinformation of the current coding unit indicates a non-square shape, theimage decoding apparatus 100 may determine one of samples adjacent to aboundary for dividing a long side of the current coding unit in half, asthe sample from which the preset information is obtainable.

According to an embodiment, when the current coding unit is split into aplurality of coding units, the image decoding apparatus 100 may use thesplit shape mode information to determine a coding unit at a presetlocation from among the plurality of coding units. According to anembodiment, the image decoding apparatus 100 may obtain the split shapemode information from a sample at a preset location in a coding unit,and may split the plurality of coding units, which are generated bysplitting the current coding unit, by using the split shape modeinformation, which is obtained from the sample of the preset location ineach of the plurality of coding units. That is, a coding unit may berecursively split based on the split shape mode information, which isobtained from the sample at the preset location in each coding unit. Anoperation of recursively splitting a coding unit has been describedabove with reference to FIG. 5, and thus detailed descriptions thereofwill not be provided here.

According to an embodiment, the image decoding apparatus 100 maydetermine one or more coding units by splitting the current coding unit,and may determine an order of decoding the one or more coding unitsbased on a preset block (e.g., the current coding unit).

FIG. 7 illustrates an order of processing a plurality of coding unitswhen the image decoding apparatus 100 determines the plurality of codingunits by splitting a current coding unit, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine second coding units 710 a and 710 b by splitting a firstcoding unit 700 in a vertical direction, may determine second codingunits 730 a and 730 b by splitting the first coding unit 700 in ahorizontal direction, or may determine second coding units 750 a, 750 b,750 c and 750 d by splitting the first coding unit 700 in vertical andhorizontal directions, based on split shape mode information.

Referring to FIG. 7, the image decoding apparatus 100 may determine toprocess the second coding units 710 a and 710 b, which are determined bysplitting the first coding unit 700 in a vertical direction, in ahorizontal direction order 710 c. The image decoding apparatus 100 maydetermine to process the second coding units 730 a and 730 b, which aredetermined by splitting the first coding unit 700 in a horizontaldirection, in a vertical direction order 730 c. The image decodingapparatus 100 may determine to process the second coding units 750 a,750 b, 750 c and 750 d, which are determined by splitting the firstcoding unit 700 in vertical and horizontal directions, according to apreset order (e.g., a raster scan order or Z-scan order 750 e) by whichcoding units in a row are processed and then coding units in a next roware processed.

According to an embodiment, the image decoding apparatus 100 mayrecursively split coding units. Referring to FIG. 7, the image decodingapparatus 100 may determine the plurality of second coding units 710 a,710 b, 730 a, 730 b, 750 a, 750 b, 750 c, and 750 d by splitting thefirst coding unit 700, and may recursively split each of the determinedplurality of second coding units 710 a, 710 b, 730 a, 730 b, 750 a, 750b, 750 c, and 750 d. A splitting method of the plurality of secondcoding units 710 a, 710 b, 730 a, 730 b, 750 a, 750 b, 750 c, and 750 dmay correspond to a splitting method of the first coding unit 700. Assuch, each of the plurality of second coding units 710 a, 710 b, 730 a,730 b, 750 a, 750 b, 750 c, and 750 d may be independently split into aplurality of coding units. Referring to FIG. 7, the image decodingapparatus 100 may determine the second coding units 710 a and 710 b bysplitting the first coding unit 700 in a vertical direction, and maydetermine to independently split or not to split each of the secondcoding units 710 a and 710 b.

According to an embodiment, the image decoding apparatus 100 maydetermine third coding units 720 a and 720 b by splitting the leftsecond coding unit 710 a in a horizontal direction, and may not splitthe right second coding unit 710 b.

According to an embodiment, a processing order of coding units may bedetermined based on an operation of splitting a coding unit. In otherwords, a processing order of split coding units may be determined basedon a processing order of coding units immediately before being split.The image decoding apparatus 100 may determine a processing order of thethird coding units 720 a and 720 b determined by splitting the leftsecond coding unit 710 a, independently of the right second coding unit710 b. Because the third coding units 720 a and 720 b are determined bysplitting the left second coding unit 710 a in a horizontal direction,the third coding units 720 a and 720 b may be processed in a verticaldirection order 720 c. Because the left and right second coding units710 a and 710 b are processed in the horizontal direction order 710 c,the right second coding unit 710 b may be processed after the thirdcoding units 720 a and 720 b included in the left second coding unit 710a are processed in the vertical direction order 720 c. An operation ofdetermining a processing order of coding units based on a coding unitbefore being split is not limited to the above-described example, andvarious methods may be used to independently process coding units, whichare split and determined to various shapes, in a preset order.

FIG. 8 illustrates a process, performed by the image decoding apparatus100, of determining that a current coding unit is to be split into anodd number of coding units, when the coding units are not processable ina preset order, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine whether the current coding unit is to be split into an oddnumber of coding units, based on obtained split shape mode information.Referring to FIG. 8, a square first coding unit 800 may be split intonon-square second coding units 810 a and 810 b, and the second codingunits 810 a and 810 b may be independently split into third coding units820 a and 820 b, and 820 c to 820 e. According to an embodiment, theimage decoding apparatus 100 may determine the plurality of third codingunits 820 a and 820 b by splitting the left second coding unit 810 a ina horizontal direction, and may split the right second coding unit 810 binto an odd number of third coding units 820 c to 820 e.

According to an embodiment, the image decoding apparatus 100 maydetermine whether any coding unit is to be split into an odd number ofcoding units, by determining whether the third coding units 820 a and820 b, and 820 c to 820 e are processable in a preset order. Referringto FIG. 8, the image decoding apparatus 100 may determine the thirdcoding units 820 a and 820 b, and 820 c to 820 e by recursivelysplitting the first coding unit 800. The image decoding apparatus 100may determine whether any of the first coding unit 800, the secondcoding units 810 a and 810 b, or the third coding units 820 a, 820 b,820 c, 820 d and 820 e is to be split into an odd number of codingunits, based on at least one of block shape information and split shapemode information. For example, a second coding unit located in the rightfrom among the second coding units 810 a and 810 b may be split into anodd number of third coding units 820 c, 820 d, and 820 e. A processingorder of a plurality of coding units included in the first coding unit800 may be a preset order (e.g., a Z-scan order 830), and the imagedecoding apparatus 100 may determine whether the third coding units 820c, 820 d, and 820 e, which are determined by splitting the right secondcoding unit 810 b into an odd number of coding units, satisfy acondition for processing in the preset order.

According to an embodiment, the image decoding apparatus 100 maydetermine whether the third coding units 820 a and 820 b, and 820 c, 820d, and 820 e included in the first coding unit 800 satisfy the conditionfor processing in the preset order, and the condition relates to whetherat least one of a width and height of the second coding units 810 a and810 b is to be divided in half along a boundary of the third codingunits 820 a and 820 b, and 820 c, 820 d, and 820 e. For example, thethird coding units 820 a and 820 b determined by dividing the height ofthe non-square left second coding unit 810 a in half may satisfy thecondition. However, because boundaries of the third coding units 820 c,820 d, and 820 e determined by splitting the right second coding unit810 b into three coding units do not divide the width or height of theright second coding unit 810 b in half, it may be determined that thethird coding units 820 c, 820 d, and 820 e do not satisfy the condition.When the condition is not satisfied as described above, the imagedecoding apparatus 100 may decide disconnection of a scan order, anddetermine that the right second coding unit 810 b is to be split into anodd number of coding units, based on a result of the decision. Accordingto an embodiment, when a coding unit is split into an odd number ofcoding units, the image decoding apparatus 100 may put a presetrestriction on a coding unit at a preset location among the split codingunits, and the restriction or the preset location has been describedabove through various embodiments and thus detailed descriptions thereofwill not be provided here.

FIG. 9 illustrates a process, performed by the image decoding apparatus100, of determining at least one coding unit by splitting a first codingunit 900, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 may splitthe first coding unit 900, based on split shape mode information, whichis obtained by the receiver 110. The square first coding unit 900 may besplit into four square coding units, or may be split into a plurality ofnon-square coding units. For example, referring to FIG. 9, when thefirst coding unit 900 has a square shape and the split shape modeinformation indicates to split the first coding unit 900 into non-squarecoding units, the image decoding apparatus 100 may split the firstcoding unit 900 into a plurality of non-square coding units. In detail,when the split shape mode information indicates to determine an oddnumber of coding units by splitting the first coding unit 900 in ahorizontal direction or a vertical direction, the image decodingapparatus 100 may split the square first coding unit 900 into an oddnumber of coding units, e.g., second coding units 910 a, 910 b, and 910c determined by splitting the square first coding unit 900 in a verticaldirection or second coding units 920 a, 920 b, and 920 c determined bysplitting the square first coding unit 900 in a horizontal direction.

According to an embodiment, the image decoding apparatus 100 maydetermine whether the second coding units 910 a, 910 b, 910 c, 920 a,920 b, and 920 c included in the first coding unit 900 satisfy acondition for processing in a preset order, and the condition relates towhether at least one of a width and height of the first coding unit 900is to be divided in half along a boundary of the second coding units 910a, 910 b, 910 c, 920 a, 920 b, and 920 c. Referring to FIG. 9, becauseboundaries of the second coding units 910 a, 910 b, and 910 c determinedby splitting the square first coding unit 900 in a vertical direction donot divide the width of the first coding unit 900 in half, it may bedetermined that the first coding unit 900 does not satisfy the conditionfor processing in the preset order. In addition, because boundaries ofthe second coding units 920 a, 920 b, and 920 c determined by splittingthe square first coding unit 900 in a horizontal direction do not dividethe width of the first coding unit 900 in half, it may be determinedthat the first coding unit 900 does not satisfy the condition forprocessing in the preset order. When the condition is not satisfied asdescribed above, the image decoding apparatus 100 may decidedisconnection of a scan order, and may determine that the first codingunit 900 is to be split into an odd number of coding units, based on aresult of the decision. According to an embodiment, when a coding unitis split into an odd number of coding units, the image decodingapparatus 100 may put a preset restriction on a coding unit at a presetlocation from among the split coding units, and the restriction or thepreset location has been described above through various embodiments andthus detailed descriptions thereof will not be provided here.

According to an embodiment, the image decoding apparatus 100 maydetermine various-shaped coding units by splitting a first coding unit.

Referring to FIG. 9, the image decoding apparatus 100 may split thesquare first coding unit 900 or a non-square first coding unit 930 or950 into various-shaped coding units.

FIG. 10 illustrates that a shape into which a second coding unit issplittable by the image decoding apparatus 100 is restricted when asecond coding unit having a non-square shape, which is determined bysplitting a first coding unit 1000, satisfies a preset condition,according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine to split the square first coding unit 1000 into non-squaresecond coding units 1010 a, 1010 b, 1020 a, and 1020 b, based on splitshape mode information, which is obtained by the receiver 110. Thesecond coding units 1010 a, 1010 b, 1020 a, and 1020 b may beindependently split. As such, the image decoding apparatus 100 maydetermine to split or not to split the first coding unit 1000 into aplurality of coding units, based on the split shape mode information ofeach of the second coding units 1010 a, 1010 b, 1020 a, and 1020 b.According to an embodiment, the image decoding apparatus 100 maydetermine third coding units 1012 a and 1012 b by splitting thenon-square left second coding unit 1010 a, which is determined bysplitting the first coding unit 1000 in a vertical direction, in ahorizontal direction. However, when the left second coding unit 1010 ais split in a horizontal direction, the image decoding apparatus 100 mayrestrict the right second coding unit 1010 b to not be split in ahorizontal direction in which the left second coding unit 1010 a issplit. When third coding units 1014 a and 1014 b are determined bysplitting the right second coding unit 1010 b in the same direction,because the left and right second coding units 1010 a and 1010 b areindependently split in a horizontal direction, the third coding units1012 a, 1012 b, 1014 a, and 1014 b may be determined. However, this caseserves equally as a case in which the image decoding apparatus 100splits the first coding unit 1000 into four square second coding units1030 a, 1030 b, 1030 c, and 1030 d, based on the split shape modeinformation, and may be inefficient in terms of image decoding.

According to an embodiment, the image decoding apparatus 100 maydetermine third coding units 1022 a, 1022 b, 1024 a, and 1024 b bysplitting the non-square second coding unit 1020 a or 1020 b, which isdetermined by splitting the first coding unit 1000 in a horizontaldirection, in a vertical direction. However, when a second coding unit(e.g., the upper second coding unit 1020 a) is split in a verticaldirection, for the above-described reason, the image decoding apparatus100 may restrict the other second coding unit (e.g., the lower secondcoding unit 1020 b) to not be split in a vertical direction in which theupper second coding unit 1020 a is split.

FIG. 11 illustrates a process, performed by the image decoding apparatus100, of splitting a square coding unit when split shape mode informationindicates that the square coding unit is not to be split into foursquare coding units, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine second coding units 1110 a, 1110 b, 1120 a, 1120 b, etc. bysplitting a first coding unit 1100 based on split shape modeinformation. The split shape mode information may include informationabout various shapes by which a coding unit is splittable but, theinformation about various shapes may not include information forsplitting a coding unit into four square coding units. According to suchsplit shape mode information, the image decoding apparatus 100 cannotsplit the first square coding unit 1100 into four square second codingunits 1130 a, 1130 b, 1130 c, and 1130 d. The image decoding apparatus100 may determine the non-square second coding units 1110 a, 1110 b,1120 a, 1120 b, etc., based on the split shape mode information.

According to an embodiment, the image decoding apparatus 100 mayindependently split the non-square second coding units 1110 a, 1110 b,1120 a, 1120 b, etc. Each of the second coding units 1110 a, 1110 b,1120 a, 1120 b, etc. may be recursively split in a preset order, andthis splitting method may correspond to a method of splitting the firstcoding unit 1100, based on the split shape mode information.

For example, the image decoding apparatus 100 may determine square thirdcoding units 1112 a and 1112 b by splitting the left second coding unit1110 a in a horizontal direction, and may determine square third codingunits 1114 a and 1114 b by splitting the right second coding unit 1110 bin a horizontal direction. Furthermore, the image decoding apparatus 100may determine square third coding units 1116 a, 1116 b, 1116 c, and 1116d by splitting both of the left and right second coding units 1110 a and1110 b in a horizontal direction. In this case, coding units having thesame shape as the four square second coding units 1130 a, 1130 b, 1130c, and 1130 d split from the first coding unit 1100 may be determined.

As another example, the image decoding apparatus 100 may determinesquare third coding units 1122 a and 1122 b by splitting the uppersecond coding unit 1120 a in a vertical direction, and may determinesquare third coding units 1124 a and 1124 b by splitting the lowersecond coding unit 1120 b in a vertical direction. Furthermore, theimage decoding apparatus 100 may determine square third coding units1126 a, 1126 b, 1126 c, and 1126 d by splitting both of the upper andlower second coding units 1120 a and 1120 b in a vertical direction. Inthis case, coding units having the same shape as the four square secondcoding units 1130 a, 1130 b, 1130 c, and 1130 d split from the firstcoding unit 1100 may be determined.

FIG. 12 illustrates that a processing order between a plurality ofcoding units may be changed depending on a process of splitting a codingunit, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 may split afirst coding unit 1200, based on split shape mode information. When ablock shape is a square shape and the split shape mode informationindicates to split the first coding unit 1200 in at least one ofhorizontal and vertical directions, the image decoding apparatus 100 maydetermine second coding units 1210 a, 1210 b, 1220 a, 1220 b, etc. bysplitting the first coding unit 1200. Referring to FIG. 12, thenon-square second coding units 1210 a, 1210 b, 1220 a, and 1220 bdetermined by splitting the first coding unit 1200 in only a horizontaldirection or vertical direction may be independently split based on thesplit shape mode information of each second coding unit. For example,the image decoding apparatus 100 may determine third coding units 1216a, 1216 b, 1216 c, and 1216 d by splitting the second coding units 1210a and 1210 b, which are generated by splitting the first coding unit1200 in a vertical direction, in a horizontal direction, and maydetermine third coding units 1226 a, 1226 b, 1226 c, and 1226 d bysplitting the second coding units 1220 a and 1220 b, which are generatedby splitting the first coding unit 1200 in a horizontal direction, in ahorizontal direction. An operation of splitting the second coding units1210 a, 1210 b, 1220 a, and 1220 b has been described above withreference to FIG. 11, and thus detailed descriptions thereof will not beprovided here.

According to an embodiment, the image decoding apparatus 100 may processcoding units in a preset order. An operation of processing coding unitsin a preset order has been described above with reference to FIG. 7, andthus detailed descriptions thereof will not be provided here. Referringto FIG. 12, the image decoding apparatus 100 may determine four squarethird coding units 1216 a, 1216 b, 1216 c, and 1216 d, and 1226 a, 1226b, 1226 c, and 1226 d by splitting the square first coding unit 1200.According to an embodiment, the image decoding apparatus 100 maydetermine processing orders of the third coding units 1216 a, 1216 b,1216 c, and 1216 d, and 1226 a, 1226 b, 1226 c, and 1226 d based on asplitting method of the first coding unit 1200.

According to an embodiment, the image decoding apparatus 100 maydetermine the third coding units 1216 a, 1216 b, 1216 c, and 1216 d bysplitting the second coding units 1210 a and 1210 b generated bysplitting the first coding unit 1200 in a vertical direction, in ahorizontal direction, and may process the third coding units 1216 a,1216 b, 1216 c, and 1216 d in a processing order 1217 for initiallyprocessing the third coding units 1216 a and 1216 c, which are includedin the left second coding unit 1210 a, in a vertical direction and thenprocessing the third coding unit 1216 b and 1216 d, which are includedin the right second coding unit 1210 b, in a vertical direction.

According to an embodiment, the image decoding apparatus 100 maydetermine the third coding units 1226 a, 1226 b, 1226 c, and 1226 d bysplitting the second coding units 1220 a and 1220 b generated bysplitting the first coding unit 1200 in a horizontal direction, in avertical direction, and may process the third coding units 1226 a, 1226b, 1226 c, and 1226 d in a processing order 1227 for initiallyprocessing the third coding units 1226 a and 1226 b, which are includedin the upper second coding unit 1220 a, in a horizontal direction andthen processing the third coding unit 1226 c and 1226 d, which areincluded in the lower second coding unit 1220 b, in a horizontaldirection.

Referring to FIG. 12, the square third coding units 1216 a, 1216 b, 1216c, and 1216 d, and 1226 a, 1226 b, 1226 c, and 1226 d may be determinedby splitting the second coding units 1210 a, 1210 b, 1220 a, and 1220 b,respectively. Although the second coding units 1210 a and 1210 b aredetermined by splitting the first coding unit 1200 in a verticaldirection differently from the second coding units 1220 a and 1220 bwhich are determined by splitting the first coding unit 1200 in ahorizontal direction, the third coding units 1216 a, 1216 b, 1216 c, and1216 d, and 1226 a, 1226 b, 1226 c, and 1226 d split therefromeventually show same-shaped coding units split from the first codingunit 1200. As such, by recursively splitting a coding unit in differentmanners based on the split shape mode information, the image decodingapparatus 100 may process a plurality of coding units in differentorders even when the coding units are eventually determined to be thesame shape.

FIG. 13 illustrates a process of determining a depth of a coding unit asa shape and a size of the coding unit change, when the coding unit isrecursively split such that a plurality of coding units are determined,according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine the depth of the coding unit, based on a preset criterion. Forexample, the preset criterion may be the length of a long side of thecoding unit. When the length of a long side of a coding unit beforebeing split is 2n times (n>0) the length of a long side of a splitcurrent coding unit, the image decoding apparatus 100 may determine thata depth of the current coding unit is increased from a depth of thecoding unit before being split, by n. In the following description, acoding unit having an increased depth is expressed as a coding unit of adeeper depth.

Referring to FIG. 13, according to an embodiment, the image decodingapparatus 100 may determine a second coding unit 1302, a third codingunit 1304, etc. of deeper depths by splitting a square first coding unit1300 based on block shape information indicating a square shape (e.g.,the block shape information may be expressed as ‘0: SQUARE’). Assumingthat the size of the square first coding unit 1300 is 2N×2N, the secondcoding unit 1302 determined by dividing a width and height of the firstcoding unit 1300 in ½ may have a size of N×N. Furthermore, the thirdcoding unit 1304 determined by dividing a width and height of the secondcoding unit 1302 in ½ may have a size of N/2×N/2. In this case, a widthand height of the third coding unit 1304 are ¼ times those of the firstcoding unit 1300. When a depth of the first coding unit 1300 is D, adepth of the second coding unit 1302, the width and height of which are½ times those of the first coding unit 1300, may be D+1, and a depth ofthe third coding unit 1304, the width and height of which are ¼ timesthose of the first coding unit 1300, may be D+2.

According to an embodiment, the image decoding apparatus 100 maydetermine a second coding unit 1312 or 1322, a third coding unit 1314 or1324, etc. of deeper depths by splitting a non-square first coding unit1310 or 1320 based on block shape information indicating a non-squareshape (e.g., the block shape information may be expressed as ‘1: NS_VER’indicating a non-square shape, a height of which is longer than a width,or as ‘2: NS_HOR’ indicating a non-square shape, a width of which islonger than a height).

The image decoding apparatus 100 may determine the second coding unit1302, 1312, or 1322 by dividing at least one of a width and height ofthe first coding unit 1310 having a size of N×2N. That is, the imagedecoding apparatus 100 may determine the second coding unit 1302 havinga size of N×N or the second coding unit 1322 having a size of N×N/2 bysplitting the first coding unit 1310 in a horizontal direction, or maydetermine the second coding unit 1312 having a size of N/2×N bysplitting the first coding unit 1310 in horizontal and verticaldirections.

According to an embodiment, the image decoding apparatus 100 maydetermine the second coding unit 1302, 1312, or 1322 by dividing atleast one of a width and height of the first coding unit 1320 having asize of 2N×N. That is, the image decoding apparatus 100 may determinethe second coding unit 1302 having a size of N×N or the second codingunit 1312 having a size of N/2×N by splitting the first coding unit 1320in a vertical direction, or may determine the second coding unit 1322having a size of N×N/2 by splitting the first coding unit 1320 inhorizontal and vertical directions.

According to an embodiment, the image decoding apparatus 100 maydetermine the third coding unit 1304, 1314, or 1324 by dividing at leastone of a width and height of the second coding unit 1302 having a sizeof N×N. That is, the image decoding apparatus 100 may determine thethird coding unit 1304 having a size of N/2×N/2, the third coding unit1314 having a size of N/4×N/2, or the third coding unit 1324 having asize of N/2×N/4 by splitting the second coding unit 1302 in vertical andhorizontal directions.

According to an embodiment, the image decoding apparatus 100 maydetermine the third coding unit 1304, 1314, or 1324 by dividing at leastone of a width and height of the second coding unit 1312 having a sizeof N/2×N. That is, the image decoding apparatus 100 may determine thethird coding unit 1304 having a size of N/2×N/2 or the third coding unit1324 having a size of N/2×N/4 by splitting the second coding unit 1312in a horizontal direction, or may determine the third coding unit 1314having a size of N/4×N/2 by splitting the second coding unit 1312 invertical and horizontal directions.

According to an embodiment, the image decoding apparatus 100 maydetermine the third coding unit 1304, 1314, or 1324 by dividing at leastone of a width and height of the second coding unit 1322 having a sizeof N×N/2. That is, the image decoding apparatus 100 may determine thethird coding unit 1304 having a size of N/2×N/2 or the third coding unit1314 having a size of N/4×N/2 by splitting the second coding unit 1322in a vertical direction, or may determine the third coding unit 1324having a size of N/2×N/4 by splitting the second coding unit 1322 invertical and horizontal directions.

According to an embodiment, the image decoding apparatus 100 may splitthe square coding unit 1300, 1302, or 1304 in a horizontal or verticaldirection. For example, the image decoding apparatus 100 may determinethe first coding unit 1310 having a size of N×2N by splitting the firstcoding unit 1300 having a size of 2N×2N in a vertical direction, or maydetermine the first coding unit 1320 having a size of 2N×N by splittingthe first coding unit 1300 in a horizontal direction. According to anembodiment, when a depth is determined based on the length of thelongest side of a coding unit, a depth of a coding unit determined bysplitting the first coding unit 1300 having a size of 2N×2N in ahorizontal or vertical direction may be the same as the depth of thefirst coding unit 1300.

According to an embodiment, a width and height of the third coding unit1314 or 1324 may be ¼ times those of the first coding unit 1310 or 1320.When a depth of the first coding unit 1310 or 1320 is D, a depth of thesecond coding unit 1312 or 1322, the width and height of which are ½times those of the first coding unit 1310 or 1320, may be D+1, and adepth of the third coding unit 1314 or 1324, the width and height ofwhich are ¼ times those of the first coding unit 1310 or 1320, may beD+2.

FIG. 14 illustrates depths that are determinable based on shapes andsizes of coding units, and part indexes (PIDs) that are fordistinguishing the coding units, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine various-shaped second coding units by splitting a square firstcoding unit 1400. Referring to FIG. 14, the image decoding apparatus 100may determine second coding units 1402 a and 1402 b, 1404 a and 1404 b,and 1406 a, 1406 b, 1406 c, and 1406 d by splitting the first codingunit 1400 in at least one of vertical and horizontal directions based onsplit shape mode information. That is, the image decoding apparatus 100may determine the second coding units 1402 a and 1402 b, 1404 a and 1404b, and 1406 a, 1406 b, 1406 c, and 1406 d, based on the split shape modeinformation of the first coding unit 1400.

According to an embodiment, a depth of the second coding units 1402 aand 1402 b, 1404 a and 1404 b, and 1406 a, 1406 b, 1406 c, and 1406 d,which are determined based on the split shape mode information of thesquare first coding unit 1400, may be determined based on the length ofa long side thereof. For example, because the length of a side of thesquare first coding unit 1400 equals the length of a long side of thenon-square second coding units 1402 a and 1402 b, and 1404 a and 1404 b,the first coding unit 1400 and the non-square second coding units 1402 aand 1402 b, and 1404 a and 1404 b may have the same depth, e.g., D.However, when the image decoding apparatus 100 splits the first codingunit 1400 into the four square second coding units 1406 a, 1406 b, 1406c, and 1406 d based on the split shape mode information, because thelength of a side of the square second coding units 1406 a, 1406 b, 1406c, and 1406 d is ½ times the length of a side of the first coding unit1400, a depth of the second coding units 1406 a, 1406 b, 1406 c, and1406 d may be D+1 which is deeper than the depth D of the first codingunit 1400 by 1.

According to an embodiment, the image decoding apparatus 100 maydetermine a plurality of second coding units 1412 a and 1412 b, and 1414a, 1414 b, and 1414 c by splitting a first coding unit 1410, a height ofwhich is longer than a width, in a horizontal direction based on thesplit shape mode information. According to an embodiment, the imagedecoding apparatus 100 may determine a plurality of second coding units1422 a and 1422 b, and 1424 a, 1424 b, and 1424 c by splitting a firstcoding unit 1420, a width of which is longer than a height, in avertical direction based on the split shape mode information.

According to an embodiment, a depth of the second coding units 1412 aand 1412 b, 1414 a, 1414 b, and 1414 c, 1422 a and 1422 b, and 1424 a,1424 b, and 1424 c, which are determined based on the split shape modeinformation of the non-square first coding unit 1410 or 1420, may bedetermined based on the length of a long side thereof. For example,because the length of a side of the square second coding units 1412 aand 1412 b is ½ times the length of a long side of the first coding unit1410 having a non-square shape, a height of which is longer than awidth, a depth of the square second coding units 1412 a and 1412 b isD+1 which is deeper than the depth D of the non-square first coding unit1410 by 1.

Furthermore, the image decoding apparatus 100 may split the non-squarefirst coding unit 1410 into an odd number of second coding units 1414 a,1414 b, and 1414 c based on the split shape mode information. The oddnumber of second coding units 1414 a, 1414 b, and 1414 c may include thenon-square second coding units 1414 a and 1414 c and the square secondcoding unit 1414 b. In this case, because the length of a long side ofthe non-square second coding units 1414 a and 1414 c and the length of aside of the square second coding unit 1414 b are ½ times the length of along side of the first coding unit 1410, a depth of the second codingunits 1414 a, 1414 b, and 1414 c may be D+1 which is deeper than thedepth D of the non-square first coding unit 1410 by 1. The imagedecoding apparatus 100 may determine depths of coding units split fromthe first coding unit 1420 having a non-square shape, a width of whichis longer than a height, by using the above-described method ofdetermining depths of coding units split from the first coding unit1410.

According to an embodiment, the image decoding apparatus 100 maydetermine PIDs for identifying split coding units, based on a size ratiobetween the coding units when an odd number of split coding units do nothave equal sizes. Referring to FIG. 14, the coding unit 1414 b of acenter location among the odd number of split coding units 1414 a, 1414b, and 1414 c may have a width equal to that of the other coding units1414 a and 1414 c and a height which is two times that of the othercoding units 1414 a and 1414 c. That is, in this case, the coding unit1414 b at the center location may include two of the other coding unit1414 a or 1414 c. Therefore, when a PID of the coding unit 1414 b at thecenter location is 1 based on a scan order, a PID of the coding unit1414 c located next to the coding unit 1414 b may be increased by 2 andthus may be 3. That is, discontinuity in PID values may be present.According to an embodiment, the image decoding apparatus 100 maydetermine whether an odd number of split coding units do not have equalsizes, based on whether discontinuity is present in PIDs for identifyingthe split coding units.

According to an embodiment, the image decoding apparatus 100 maydetermine whether to use a specific split shape, based on PID values foridentifying a plurality of coding units determined by splitting acurrent coding unit. Referring to FIG. 14, the image decoding apparatus100 may determine an even number of coding units 1412 a and 1412 b or anodd number of coding units 1414 a, 1414 b, and 1414 c by splitting thefirst coding unit 1410 having a rectangular shape, a height of which islonger than a width. The image decoding apparatus 100 may use PIDs toidentify respective coding units. According to an embodiment, the PIDmay be obtained from a sample of a preset location (e.g., an upper-leftsample) of each coding unit.

According to an embodiment, the image decoding apparatus 100 maydetermine a coding unit of a preset location from among the split codingunits, by using the PIDs for distinguishing the coding units. Accordingto an embodiment, when the split shape mode information of the firstcoding unit 1410 having a rectangular shape, a height of which is longerthan a width, indicates to split a coding unit into three coding units,the image decoding apparatus 100 may split the first coding unit 1410into three coding units 1414 a, 1414 b, and 1414 c. The image decodingapparatus 100 may assign a PID to each of the three coding units 1414 a,1414 b, and 1414 c. The image decoding apparatus 100 may compare PIDs ofan odd number of split coding units to determine a coding unit at acenter location from among the coding units. The image decodingapparatus 100 may determine the coding unit 1414 b having a PIDcorresponding to a middle value among the PIDs of the coding units, asthe coding unit of the center location from among the coding unitsdetermined by splitting the first coding unit 1410. According to anembodiment, the image decoding apparatus 100 may determine PIDs fordistinguishing split coding units, based on a size ratio between thecoding units when the split coding units do not have equal sizes.Referring to FIG. 14, the coding unit 1414 b generated by splitting thefirst coding unit 1410 may have a width equal to that of the othercoding units 1414 a and 1414 c and a height which is two times that ofthe other coding units 1414 a and 1414 c. In this case, when the PID ofthe coding unit 1414 b at the center location is 1, the PID of thecoding unit 1414 c located next to the coding unit 1414 b may beincreased by 2 and thus may be 3. When the PID is not uniformlyincreased as described above, the image decoding apparatus 100 maydetermine that a coding unit is split into a plurality of coding unitsincluding a coding unit having a size different from that of the othercoding units. According to an embodiment, when the split shape modeinformation indicates to split a coding unit into an odd number ofcoding units, the image decoding apparatus 100 may split a currentcoding unit in such a manner that a coding unit of a preset location(e.g., a coding unit of a center location) among an odd number of codingunits has a size different from that of the other coding units. In thiscase, the image decoding apparatus 100 may determine the coding unit ofthe center location, which has a different size, by using PIDs of thecoding units. However, the PID and the size or location of the codingunit of the preset location to be determined are not limited to theabove-described examples, and various PIDs and various locations andsizes of coding units may be used.

According to an embodiment, the image decoding apparatus 100 may use apreset data unit where a coding unit starts to be recursively split.

FIG. 15 illustrates that a plurality of coding units are determinedbased on a plurality of preset data units included in a picture,according to an embodiment.

According to an embodiment, a preset data unit may be defined as a dataunit where a coding unit starts to be recursively split by using splitshape mode information. That is, the preset data unit may correspond toa coding unit of an uppermost depth, which is used to determine aplurality of coding units split from a current picture. In the followingdescriptions, for convenience of explanation, the preset data unit isreferred to as a reference data unit.

According to an embodiment, the reference data unit may have a presetsize and a preset shape. According to an embodiment, a reference codingunit may include M×N samples. Herein, M and N may be equal to eachother, and may be integers expressed as powers of 2. That is, thereference data unit may have a square or non-square shape, and may besplit into an integer number of coding units.

According to an embodiment, the image decoding apparatus 100 may splitthe current picture into a plurality of reference data units. Accordingto an embodiment, the image decoding apparatus 100 may split theplurality of reference data units, which are split from the currentpicture, by using split shape mode information for each reference dataunit. The operation of splitting the reference data unit may correspondto a splitting operation using a quadtree structure.

According to an embodiment, the image decoding apparatus 100 maypreviously determine the minimum size allowed for the reference dataunits included in the current picture. Accordingly, the image decodingapparatus 100 may determine various reference data units having sizesequal to or greater than the minimum size, and may determine one or morecoding units by using the split shape mode information with reference tothe determined reference data unit.

Referring to FIG. 15, the image decoding apparatus 100 may use a squarereference coding unit 1500 or a non-square reference coding unit 1502.According to an embodiment, the shape and size of reference coding unitsmay be determined based on various data units capable of including oneor more reference coding units (e.g., sequences, pictures, slices, slicesegments, largest coding units, or the like).

According to an embodiment, the receiver 110 of the image decodingapparatus 100 may obtain, from a bitstream, at least one of referencecoding unit shape information and reference coding unit size informationwith respect to each of the various data units. An operation ofdetermining one or more coding units included in the square referencecoding unit 1500 has been described above in relation to the operationof splitting the current coding unit 300 of FIG. 3, and an operation ofdetermining one or more coding units included in the non-squarereference coding unit 1502 has been described above in relation to theoperation of splitting the current coding unit 400 or 450 of FIG. 4, andthus, detailed descriptions thereof will not be provided here.

According to an embodiment, the image decoding apparatus 100 may use aPID for identifying the size and shape of reference coding units, todetermine the size and shape of reference coding units according to somedata units previously determined based on a preset condition. That is,the receiver 110 may obtain, from the bitstream, only the PID foridentifying the size and shape of reference coding units with respect toeach slice, slice segment, or largest coding unit which is a data unitsatisfying a preset condition (e.g., a data unit having a size equal toor smaller than a slice) among the various data units (e.g., sequences,pictures, slices, slice segments, largest coding units, or the like).The image decoding apparatus 100 may determine the size and shape ofreference data units with respect to each data unit, which satisfies thepreset condition, by using the PID. When the reference coding unit shapeinformation and the reference coding unit size information are obtainedand used from the bitstream according to each data unit having arelatively small size, efficiency of using the bitstream may not behigh, and therefore, only the PID may be obtained and used instead ofdirectly obtaining the reference coding unit shape information and thereference coding unit size information. In this case, at least one ofthe size and shape of reference coding units corresponding to the PIDfor identifying the size and shape of reference coding units may bepredetermined. That is, the image decoding apparatus 100 may determineat least one of the size and shape of reference coding units included ina data unit serving as a unit for obtaining the PID, by selecting thepredetermined at least one of the size and shape of reference codingunits based on the PID.

According to an embodiment, the image decoding apparatus 100 may use oneor more reference coding units included in a largest coding unit. Thatis, a largest coding unit split from a picture may include one or morereference coding units, and coding units may be determined byrecursively splitting each reference coding unit. According to anembodiment, at least one of a width and height of the largest codingunit may be integer times at least one of the width and height of thereference coding units. According to an embodiment, the size ofreference coding units may be obtained by splitting the largest codingunit n times based on a quadtree structure. That is, the image decodingapparatus 100 may determine the reference coding units by splitting thelargest coding unit n times based on a quadtree structure, and may splitthe reference coding unit based on at least one of the block shapeinformation and the split shape mode information according to variousembodiments.

FIG. 16 illustrates a processing block serving as a unit for determininga determination order of reference coding units included in a picture1600, according to an embodiment.

According to an embodiment, the image decoding apparatus 100 maydetermine one or more processing blocks split from a picture. Theprocessing block is a data unit including one or more reference codingunits split from an image, and the one or more reference coding unitsincluded in the processing block may be determined according to aspecific order. That is, a determination order of one or more referencecoding units determined in each processing block may correspond to oneof various types of orders for determining reference coding units, andmay vary depending on the processing block. The determination order ofreference coding units, which is determined with respect to eachprocessing block, may be one of various orders, e.g., raster scan,Z-scan, N-scan, up-right diagonal scan, horizontal scan, and verticalscan, but is not limited to the above-mentioned scan orders.

According to an embodiment, the image decoding apparatus 100 may obtainprocessing block size information and may determine the size of one ormore processing blocks included in the image. The image decodingapparatus 100 may obtain the processing block size information from abitstream and may determine the size of one or more processing blocksincluded in the image. The size of processing blocks may be a presetsize of data units, which is indicated by the processing block sizeinformation.

According to an embodiment, the receiver 110 of the image decodingapparatus 100 may obtain the processing block size information from thebitstream according to each specific data unit. For example, theprocessing block size information may be obtained from the bitstream ina data unit such as an image, sequence, picture, slice, or slicesegment. That is, the receiver 110 may obtain the processing block sizeinformation from the bitstream according to each of the various dataunits, the image decoding apparatus 100 may determine the size of one ormore processing blocks, which are split from the picture, by using theobtained processing block size information, and the size of theprocessing blocks may be integer times that of the reference codingunits.

According to an embodiment, the image decoding apparatus 100 maydetermine the size of processing blocks 1602 and 1612 included in thepicture 1600. For example, the image decoding apparatus 100 maydetermine the size of processing blocks based on the processing blocksize information obtained from the bitstream. Referring to FIG. 16,according to an embodiment, the image decoding apparatus 100 maydetermine a width of the processing blocks 1602 and 1612 to be fourtimes the width of the reference coding units, and may determine aheight of the processing blocks 1602 and 1612 to be four times theheight of the reference coding units. The image decoding apparatus 100may determine a determination order of one or more reference codingunits in one or more processing blocks.

According to an embodiment, the image decoding apparatus 100 maydetermine the processing blocks 1602 and 1612, which are included in thepicture 1600, based on the size of processing blocks, and may determinea determination order of one or more reference coding units included inthe processing blocks 1602 and 1612. According to an embodiment,determination of reference coding units may include determination of thesize of the reference coding units.

According to an embodiment, the image decoding apparatus 100 may obtain,from the bitstream, determination order information of one or morereference coding units included in one or more processing blocks, andmay determine a determination order with respect to one or morereference coding units based on the obtained determination orderinformation. The determination order information may be defined as anorder or direction for determining the reference coding units in theprocessing block. That is, the determination order of reference codingunits may be independently determined with respect to each processingblock.

According to an embodiment, the image decoding apparatus 100 may obtain,from the bitstream, the determination order information of referencecoding units according to each specific data unit. For example, thereceiver 110 may obtain the determination order information of referencecoding units from the bitstream according to each data unit such as animage, sequence, picture, slice, slice segment, or processing block.Because the determination order information of reference coding unitsindicates an order for determining reference coding units in aprocessing block, the determination order information may be obtainedwith respect to each specific data unit including an integer number ofprocessing blocks.

According to an embodiment, the image decoding apparatus 100 maydetermine one or more reference coding units based on the determineddetermination order.

According to an embodiment, the receiver 110 may obtain thedetermination order information of reference coding units from thebitstream as information related to the processing blocks 1602 and 1612,and the image decoding apparatus 100 may determine a determination orderof one or more reference coding units included in the processing blocks1602 and 1612 and determine one or more reference coding units, whichare included in the picture 1600, based on the determination order.Referring to FIG. 16, the image decoding apparatus 100 may determinedetermination orders 1604 and 1614 of one or more reference coding unitsin the processing blocks 1602 and 1612, respectively. For example, whenthe determination order information of reference coding units isobtained with respect to each processing block, different kinds of thedetermination order information of reference coding units may beobtained for the processing blocks 1602 and 1612. When the determinationorder 1604 of reference coding units in the processing block 1602 is araster scan order, reference coding units included in the processingblock 1602 may be determined according to the raster scan order. On thecontrary, when the determination order 1614 of reference coding units inthe other processing block 1612 is a backward raster scan order,reference coding units included in the processing block 1612 may bedetermined according to the backward raster scan order.

According to an embodiment, the image decoding apparatus 100 may decodethe determined one or more reference coding units. The image decodingapparatus 100 may decode an image, based on the reference coding unitsdetermined as described above. A method of decoding the reference codingunits may include various image decoding methods.

According to an embodiment, the image decoding apparatus 100 may obtainblock shape information indicating the shape of a current coding unit orsplit shape mode information indicating a splitting method of thecurrent coding unit, from the bitstream, and may use the obtainedinformation. The split shape mode information may be included in thebitstream related to various data units. For example, the image decodingapparatus 100 may use the split shape mode information included in asequence parameter set, a picture parameter set, a video parameter set,a slice header, or a slice segment header. Furthermore, the imagedecoding apparatus 100 may obtain, from the bitstream, a syntax elementcorresponding to the block shape information or the split shape modeinformation according to each largest coding unit, each reference codingunit, or each processing block, and may use the obtained syntax element.

Hereinafter, a method of determining a split rule according to anembodiment of the present disclosure will be described in detail.

The image decoding apparatus 100 may determine a split rule of an image.The split rule may be pre-determined between the image decodingapparatus 100 and the image encoding apparatus 200. The image decodingapparatus 100 may determine the split rule of the image, based oninformation obtained from a bitstream, The image decoding apparatus 100may determine the split rule, based on information obtained from atleast one of a sequence parameter set, a picture parameter set, a videoparameter set, a slice header, and a slice segment header. The imagedecoding apparatus 100 may differently determine the split ruleaccording to a frame, a slice, a temporal layer, a largest coding unit,or a coding unit.

The image decoding apparatus 100 may determine the split rule, based ona block shape of a coding unit. The block shape may include a size, ashape, a ratio of a width to a height, and a direction of the codingunit. The image encoding apparatus 200 and the image decoding apparatus100 may previously determine to determine the split rule, based on theblock shape of the coding unit. However, the present disclosure is notlimited thereto. The image decoding apparatus 100 may determine thesplit rule, based on the information obtained from the bitstreamreceived from the image encoding apparatus 200.

The shape of the coding unit may include a square shape and a non-squareshape. When the width and the height of the coding unit are the same,the image decoding apparatus 100 may determine that the shape of thecoding unit is a square shape. Also, when the width and the height ofthe coding unit are not the same, the image decoding apparatus 100 maydetermine that the shape of the coding unit is a non-square shape.

The size of the coding unit may include various sizes such as 4×4, 8×4,4×8, 8×8, 16×4, 16×8, . . . , and 256×256. The size of the coding unitmay be classified according to the length of a long side, the length ofa short side, or the area of the coding unit. The image decodingapparatus 100 may apply the same split rule to coding units classifiedin the same group. For example, the image decoding apparatus 100 mayclassify coding units whose long sides have the same length as codingunits having the same size. Also, the image decoding apparatus 100 mayapply the same split rule to coding units whose long sides have the samelength.

The ratio of the width to the height of the coding unit may include 1:2,2:1, 1:4, 4:1, 1:8, 8:1, 1:16, 16:1, 32:1 or 1:32. Also, the directionof the coding unit may include a horizontal direction and a verticaldirection. The horizontal direction may indicate a case where the lengthof the width of the coding unit is greater than the length of the heightof the coding unit. The vertical direction may indicate a case where thelength of the width of the coding unit is smaller than the length of theheight of the coding unit.

The image decoding apparatus 100 may adaptively determine the splitrule, based on the size of the coding unit. The image decoding apparatus100 may differently determine an allowable split shape mode based on thesize of the coding unit. For example, the image decoding apparatus 100may determine whether splitting is allowed based on the size of thecoding unit. The image decoding apparatus 100 may determine a splitdirection according to the size of the coding unit. The image decodingapparatus 100 may determine an allowable split type according to thesize of the coding unit.

The split rule determined based on the size of the coding unit may be asplit rule pre-determined between the image encoding apparatus 2200 andthe image decoding apparatus 100. Also, the image decoding apparatus 100may determine the split rule, based on the information obtained from thebitstream.

The image decoding apparatus 100 may adaptively determine the split rulebased on a location of the coding unit. The image decoding apparatus 100may adaptively determine the split rule based on the location of thecoding unit in the image.

Also, the image decoding apparatus 100 may determine the split rule suchthat coding units generated via different split paths do not have thesame block shape. However, the present disclosure is not limitedthereto, and the coding units generated via different split paths mayhave the same block shape. The coding units generated via differentsplit paths may have different decoding processing orders. A decodingprocessing order has been described with reference to FIG. 12, and thusdetailed descriptions thereof are not provided here.

Hereinafter, with reference to FIGS. 17 to 20, a method and apparatusfor encoding or decoding a video by configuring an additional mode setbased on MPM modes of a current block, determining an intra predictionmode of the current block based on the MPM modes and the additional modeset, and performing intra prediction on the current block, based on thedetermined intra prediction mode according to an embodiment disclosed inthe present disclosure application will now be described.

FIG. 17 illustrates a block diagram of a video decoding apparatus 1700,according to an embodiment.

The video decoding apparatus 1700 according to an embodiment may includea memory 1710 and at least one processor 1720 connected with the memory1710. Operations of the video decoding apparatus 1700 according to anembodiment may be performed by separate processors or may be performedby the control of a central processor. Also, the memory 1710 of thevideo decoding apparatus 1700 may store data received from an externalsource, and data generated by a processor, e.g., information about theMPM modes of the current block and information about the configuredadditional mode set.

The processor 1720 of the video decoding apparatus 1700 may configurethe additional mode set including at least one candidate mode, based onthe MPM modes of the current block, may determine the intra predictionmode of the current block based on the MPM modes and the additional modeset, and may perform intra prediction, based on the intra predictionmode.

Hereinafter, with reference to FIG. 18, detailed operations of a videodecoding method, performed by the video decoding apparatus 1700according to an embodiment, of configuring an additional mode set basedon MPM modes of a current block, determining an intra prediction mode ofthe current block based on the MPM modes and the additional mode set,and performing intra prediction will now be described.

FIG. 18 illustrates a flowchart of a video decoding method, according toan embodiment.

Referring to FIG. 18, in operation S1810, the video decoding apparatus1700 may configure an additional mode set based on MPM modes of acurrent block.

According to an embodiment, the MPM modes of the current block mayinclude a prediction mode of a neighboring block adjacent to the leftside of the current block and a prediction mode of a neighboring blockadjacent to the top side of the current block.

According to another embodiment, a neighboring block adjacent to theright side of the current block and a neighboring block adjacent to thetop side of the current block may be reconstructed before the currentblock, and the MPM modes of the current block may include a predictionmode of the neighboring block adjacent to the right side of the currentblock and the prediction mode of the neighboring block adjacent to thetop side of the current block. In a case where the neighboring blockadjacent to the right side of the current block and the neighboringblock adjacent to the top side of the current block exist, when theneighboring block adjacent to the left side of the current blocksimultaneously exists, an MPM mode may be configured by usinginformation about the prediction mode of the left block and theprediction mode of the top block, and then an additional mode set may beconfigured by using information about the MPM mode and mode informationof the right block. When mode information of the neighboring blocksadjacent in the left side, the top side, and the right side all exist,and some of the left block, the top block, and the right block are basedon a same mode, a mode set may be configured by using only informationabout two different modes or may include more angular modes indirections close to index of duplicated mode from among modes of theneighboring blocks.

In operation S1830, the video decoding apparatus 1700 may determine anintra prediction mode of the current block, based on the MPM modes andthe additional mode set.

According to an embodiment, as the intra prediction mode of the currentblock, an optimal intra prediction mode of the current block from amongthe MPM modes and modes of the additional mode set may be determined byusing information obtained from a bitstream.

In operation S1850, the video decoding apparatus 1700 may perform intraprediction on the current block, based on the intra prediction mode.

According to an embodiment, the intra prediction mode of the currentblock is highly probable to have a relation to an intra prediction modeof a neighboring block, and thus, N intra prediction modes that arehighly probable to become the intra prediction mode of the current blockmay constitute the additional mode set, by using mode information of theneighboring block or MPM information of the current block. Theadditional mode set may be configured of an intra prediction mode havingan index that is increased by n from an intra prediction mode index of aleft block mode, and an intra prediction mode having an index that isincreased by m from an intra prediction mode index of a top block mode(where, n and m are non-zero integers). For example, when the left blockand the top block are based on an angular mode, the additional mode setmay be configured of an intra prediction mode having an index increasedby 1 from the intra prediction mode index of the left block mode, anintra prediction mode having an index increased by 1 from the intraprediction mode index of the top block mode, an intra prediction modehaving an index decreased by 1 from the intra prediction mode index ofthe left block mode, and an intra prediction mode having an indexdecreased by 1 from the intra prediction mode index of the top blockmode. Alternatively, the additional mode set may be configured of theintra prediction mode having the index increased by 1 from the intraprediction mode index of the top block mode, an intra prediction modehaving an index increased by 2 from the intra prediction mode index ofthe top block mode, an intra prediction mode having an index decreasedby 2 from the intra prediction mode index of the left block mode, and anintra prediction mode having an index obtained by averaging intraprediction mode indices of the left block mode and the top block modeand then rounding off a result thereof.

FIG. 21 illustrates an embodiment of modes of left and top neighboringblocks and a mode set of the current block.

Referring to FIG. 21, when intra prediction modes of a top neighboringblock 2120 adjacent to the top side of a current block 2110 and a leftneighboring block 2130 adjacent to the left side of the current block2110 are a vertical mode and a horizontal mode, respectively, an MPMmode of the current block 2110 may be determined as the vertical modeand the horizontal mode, and an additional mode set may include modesthat have a high relation to the MPM mode and are close to the MPM mode,the modes being from among modes between the vertical mode and thehorizontal mode. For example, the additional mode set may be configuredof an intra prediction mode having an index increased by 1 from an intraprediction mode index of the vertical mode, an intra prediction modehaving an index increased by 2 from the intra prediction mode index ofthe vertical mode, an intra prediction mode having an index decreased by2 from an intra prediction mode index of the horizontal mode, an intraprediction mode having an index decreased by 1 from the intra predictionmode index of the horizontal mode, and an intra prediction mode havingan index obtained by averaging and then rounding off intra predictionmode indices of the vertical mode and the horizontal mode.

According to an embodiment, the additional mode set may include N modes(where, N is a predetermined integer) according to the number of intraprediction modes or the number of MPMs.

According to an embodiment, the additional mode set may differentlyinclude N or M (where, N and M are positive integers) modes, accordingto a type of an intra prediction mode of a neighboring block adjacent toa current block. In detail, the additional mode set may vary accordingto a case where an intra prediction mode of the neighboring block is anangular mode and a case where an intra prediction mode of theneighboring block is a non-angular mode such as a DC mode, a planarmode, or the like.

FIG. 22 illustrates an embodiment of intra prediction mode directions.

In detail, a vertical direction 2240 that is a y-axis positive directionand a horizontal direction 2220 that is an x-axis negative direction,from among intra prediction directions of an intra prediction mode ofFIG. 22, indicate a vertical mode and a horizontal mode of the intraprediction mode, respectively. FIG. 22 also illustrates, from among theintra prediction directions, a diagonal angular mode 2250 in an upperright quadrant which is a last direction of the intra predictiondirections, a diagonal angular mode 2210 in a lower left quadrant whichis a start direction of an angular mode, and a diagonal mode 2230 thatis perpendicular to a direction of the angular mode 2250 which is a45-degree direction. The direction of the angular mode 2250 of the intraprediction mode of FIG. 22 may be a direction other than the 45-degreedirection.

According to an embodiment, the intra prediction mode may include 67modes. In detail, the intra prediction mode may include a DC mode, aplanar mode, and 65 angular modes. The intra prediction mode may bedistinguished therein by indicating indices of the intra prediction modeto be 0 to 66 (0 indicates the planar mode, 1 indicates the DC mode, and2 to 66 indicate angular modes).

Referring to FIG. 22, a mode of the intra prediction mode, the modehaving an index of 2, may be the angular mode 2210 in a directionopposite to the angular mode 2250 in the 45-degree direction, a mode ofthe intra prediction mode, the mode having an index of 34, may be thediagonal mode 2230 that is perpendicular to the direction of the angularmode 2250 which is the 45-degree direction, a mode of the intraprediction mode, the mode having an index of 66, may be the angular mode2250 in the 45-degree direction, an index of the horizontal direction2220 that is the x-axis negative direction may be 18, and an index ofthe vertical direction 2240 that is the y-axis positive direction may be50.

According to an embodiment, when the number of MPM modes is 2 and thenumber of other intra prediction modes is 65, an additional mode set mayinclude 4 or 8 modes according to types of modes selected to be the MPMmodes.

Table 1 below illustrates an example of the additional mode setconfigured according to types of two MPM modes when MPM[0] and MPM[1]respectively indicate intra prediction modes designated as MPM modes.

TABLE 1 When both MPMs are When both MPMs non-angular modes. are angularmodes. DC or planar mode Planar mode Vertical mode DC mode Horizontalmode MPM[0] − 2 Diagonal mode MPM[0] − 1 MPM[0] + 1 MPM[1] − 2 MPM[1] −1 MPM[1] + 1

In detail, when two MPM modes are all non-angular modes, an additionalmode set may include 4 modes that are DC or planar mode, a verticalmode, a horizontal mode, and a diagonal mode. Alternatively, theadditional mode set may include at least one of the DC or planar mode,the vertical mode, the horizontal mode, and the diagonal mode.

In another embodiment, when two MPM modes are all non-angular modes, theadditional mode set may include at least one of the DC or planar mode,the vertical mode, the horizontal mode, an intra prediction mode of anindex increased by 4 from an intra prediction mode index of thehorizontal mode, and, intra prediction mode of an index decreased by 4from the intra prediction mode index of the horizontal mode.

When two MPM modes are all angular modes, the additional mode set mayinclude 8 modes that are a planar mode, a DC mode, an intra predictionmode (MPM[0]-2) having an index decreased by 2 from an index of MPM[0]mode, an intra prediction mode (MPM[0]-1) having an index decreased by 1from the index of MPM[0] mode, an intra prediction mode (MPM[0]+1)having an index increased by 1 from the index of MPM[0] mode, an intraprediction mode (MPM[1]-2) having an index decreased by 2 from an indexof MPM[1] mode, an intra prediction mode (MPM[1]-1) having an indexdecreased by 1 from the index of MPM[1] mode, and an intra predictionmode (MPM[1]+1) having an index increased by 1 from the index of MPM[1]mode. Alternatively, the additional mode set may include at least one ofthe planar mode, the DC mode, the intra prediction mode (MPM[0]-2)having the index decreased by 2 from the index of MPM[0] mode, the intraprediction mode (MPM[0]-1) having the index decreased by 1 from theindex of MPM[0] mode, the intra prediction mode (MPM[0]+1) having theindex increased by 1 from the index of MPM[0] mode, the intra predictionmode (MPM[1]-2) having the index decreased by 2 from the index of MPM[1]mode, the intra prediction mode (MPM[1]-1) having the index decreased by1 from the index of MPM[1] mode, and the intra prediction mode(MPM[1]+1) having the index increased by 1 from the index of MPM[1]mode.

Alternatively, when an intra prediction mode (a candidate of MPM[0]) ofa neighboring block adjacent to the left side of a current block and anintra prediction mode (a candidate of MPM[1]) of a neighboring blockadjacent to the top side of the current block are same angular mode,MPM[0] may be determined to be the intra prediction mode of theneighboring block adjacent to the left side of the current block, andthe rest of MPM modes and an additional mode set may include 5 modesthat are a planar mode, a DC mode, an intra prediction mode (MPM[0]-2)having an index decreased by 2 from an index of MPM[0] mode, an intraprediction mode (MPM[0]-1) having an index decreased by 1 from the indexof MPM[0] mode, and an intra prediction mode (MPM[0]+1) having an indexincreased by 1 from the index of MPM[0] mode. Alternatively, MPM[0] maybe determined to be the intra prediction mode of the neighboring blockadjacent to the left side of the current block, and the rest of MPMmodes and the additional mode set may include at least one of the planarmode, the DC mode, the intra prediction mode (MPM[0]-2) having the indexdecreased by 2 from the index of MPM[0] mode, the intra prediction mode(MPM[0]-1) having the index decreased by 1 from the index of MPM[0]mode, and the intra prediction mode (MPM[0]+1) having the indexincreased by 1 from the index of MPM[0] mode.

In another embodiment, when two MPM modes are all angular modes, theadditional mode set may include at least one of the DC mode, the planarmode, an intra prediction mode having an index increased by 1 from anintra prediction mode index of an MPM mode which have greater intraprediction mode index from among the MPM modes and an intra predictionmode having an index decreased by 1 from the intra prediction mode indexof the MPM mode which have greater intra prediction mode index fromamong the MPM modes, or an intra prediction mode having an indexincreased by 2 from the intra prediction mode index of the MPM modewhich have greater intra prediction mode index from among the MPM modesand an intra prediction mode having an index decreased by 2 from theintra prediction mode index of the MPM mode which have greater intraprediction mode index from among the MPM modes.

In another embodiment, when two MPM modes are all angular modes, theadditional mode set may include at least one of the DC mode, the planarmode, and intra prediction modes having index increased by n from indexof each of the MPM modes, wherein n is a non-zero integer.

Table 2 below shows an example of an additional mode set configured whenone of the MPM modes is a non-angular mode and the other one is anangular mode, i.e., when MPM[0] is a non-angular mode and MPM[1] is anangular mode.

TABLE 2 Case where angular + non- Case where angular + non- angularmodes (4 modes) angular modes (8 modes) DC or planar mode DC or planarmode (Mode different from MPM[0]) (Mode different from MPM[0]) MPM[1] −2 MPM[1] + 2 MPM[1] + 2 MPM[1] + 1 Default mode MPM[1] − 1 MPM[1] − 2Default mode Default mode Default mode

In detail, when one of two MPM modes is a non-angular mode and the otherone is an angular mode, the additional mode set may include 4 modes thatare a mode is different from MPM[0] that is a non-angular mode fromamong “DC or planar mode”, an intra prediction mode having an indexdecreased by 2 from a mode index of MPM[1] that is an angular mode, anintra prediction mode having an index increased by 2 from the mode indexof MPM[1], and a default mode. Alternatively, the additional mode setmay include at least one of 4 modes that are the mode that is from among“DC or planar mode” and is different from MPM[0] that is a non-angularmode, the intra prediction mode having the index decreased by 2 from themode index of MPM[1] that is an angular mode, the intra prediction modehaving the index increased by 2 from the mode index of MPM[1], and thedefault mode.

Also, the additional mode set may include 8 modes that are 3 defaultmodes, the mode that is from among “DC or planar mode” and is differentfrom MPM[0] that is a non-angular mode, the intra prediction mode havingthe index decreased by 2 from the mode index of MPM[1] that is anangular mode, an intra prediction mode having an index decreased by 1from the mode index of MPM[1], an intra prediction mode having an indexincreased by 1 from the mode index of MPM[1], and the intra predictionmode having the index increased by 2 from the mode index of MPM[1].Alternatively, the additional mode set may include 3 default modes, themode that is from among “DC or planar mode” and is different from MPM[0]that is a non-angular mode, a mode of decreasing, by 2, the mode indexof MPM[1] that is an angular mode, a mode of decreasing, by 1, the modeindex of MPM[1], a mode of increasing, by 1, the mode index of MPM[1],and a mode of increasing, by 2, the mode index of MPM[1].

According to an embodiment, the additional mode set may include at leastone of the mode that is from among “DC or planar mode” and is differentfrom MPM[0] that is a non-angular mode, the intra prediction mode havingthe index decreased by 2 from the mode index of MPM[1] that is anangular mode, the intra prediction mode having the index decreased by 1from the mode index of MPM[1], and the intra prediction mode having theindex increased by 1 from the mode index of MPM[1].

According to an embodiment, a first MPM mode from among the MPM modesmay be a non-angular mode, a second MPM mode may be an angular mode, andthe additional mode set may include at least one of a mode differentfrom the first MPM mode from among the DC mode and the planar mode, anintra prediction mode having an index increased by n from an index ofthe second MPM mode, a vertical mode, and a horizontal mode, wherein nis a non-zero integer.

According to an embodiment, the default mode may be selected from adefault mode candidate list pre-configured to prepare a case in whichcandidates to be included in the additional mode set are decreased, thecase including a case where at least two candidate modes are overlappedor a case where at least one of a mode or an MPM mode of a neighboringblock is a non-angular mode. In detail, the default mode candidate listmay include intra prediction modes that are frequently selected in thestatistics, and an order of candidates included in the list may belisted from a mode having a higher probability.

According to an embodiment, for the default mode, an additional mode setmay be configured in a manner that modes that have been used up to acurrent block in a current frame are counted and then intra predictionmodes that are frequently selected are adaptively selected.Alternatively, the default mode may be selected by using a history aboutan intra prediction mode selected for a previous intra block of thecurrent block in the current frame, or may be selected by applyingpriority numbers to modes of blocks adjacent to the current block.

FIG. 23 illustrates an embodiment of an additional mode set.

Referring to FIG. 23, the additional mode set may include a verticaldirection 2340 that is a y-axis positive direction, a horizontaldirection 2320 that is an x-axis negative direction, an angular mode2350 in a 45-degree direction, an angular mode 2310 that is a directionopposite to the angular mode 2350 in a 45-degree direction, a diagonalmode 2330 that is perpendicular to a direction of the angular mode 2350which is a 45-degree direction, an angular mode 2370 in a direction bywhich an angle between the vertical direction 2340 and the angular mode2350 in a 45-degree direction is halved, and an angular mode 2360 in adirection by which an angle between the horizontal direction 2320 andthe angular mode 2310 that is a direction opposite to the angular mode2350 in a 45-degree direction is halved. In a case where an anglebetween two angular modes is halved, when there is no direction exactlycorresponding thereto, an angular mode in the most adjacent directionmay be used or an intra prediction mode having an index obtained byaveraging respective intra prediction mode indices and then rounding offa result thereof may be used.

FIGS. 19 and 20 illustrate a block diagram of a video encoding apparatus1900 according to an embodiment and a flowchart of a video encodingmethod according to an embodiment that respectively correspond to avideo decoding apparatus and a video decoding method described above.

The video encoding apparatus 1900 according to an embodiment may includea memory 1910 and at least one processor 1920 connected with the memory1910. Operations of the video encoding apparatus 1900 according to anembodiment may be performed by separate processors or may be performedby the control of a central processor. Also, the memory 1910 of thevideo encoding apparatus 1900 may store data received from an externalsource, and data generated by a processor, e.g., information about theMPM modes of the current block and information about the configuredadditional mode set.

The processor 1920 of the video encoding apparatus 1900 may configurethe additional mode set, based on the MPM modes of the current block,may determine the intra prediction mode of the current block based onthe MPM modes and the additional mode set, and may perform intraprediction, based on the intra prediction mode.

Hereinafter, with reference to FIG. 20, detailed operations of the videoencoding method, performed by the video encoding apparatus 1900according to an embodiment, of configuring an additional mode set basedon MPM modes of a current block, determining an intra prediction mode ofthe current block based on the MPM modes and the additional mode set,and performing intra prediction will now be described.

FIG. 20 illustrates a flowchart of a video encoding method, according toan embodiment.

Referring to FIG. 20, in operation S2010, the video encoding apparatus1900 may configure an additional mode set based on MPM modes of acurrent block.

According to an embodiment, the MPM modes of the current block may bedetermined by using prediction modes of a neighboring block.

In operation S2030, the video encoding apparatus 1900 may determine anintra prediction mode of the current block, based on the MPM modes andthe additional mode set.

According to an embodiment, the video encoding apparatus 1900 may encodeintra prediction mode information by comparing the MPM modes and modesof the additional mode set with an optimal intra prediction modedetermined in the current block. The optimal intra prediction mode ofthe current block may be determined by calculating rate-distortion costof the current block.

In operation S2050, the video encoding apparatus 1900 may perform intraprediction on the current block, based on the intra prediction mode.

FIG. 24 illustrates an embodiment of intra prediction mode signalingsyntax.

Referring to FIG. 24, when an MPM flag indicates 1, intra prediction isperformed by using an MPM mode. When an MPM flag indicates 0, a flag ofan additional mode set is checked and thus, when the flag of theadditional mode set indicates 1, intra prediction is performed by usingN modes of the additional mode set, and when the flag of the additionalmode set indicates 0, intra prediction may be performed by using otherremaining intra prediction mode. When the number of modes of theadditional mode set is N, the flag of the additional mode set may becoded with allocated log₂(N) bits and then may be signaled.

According to an embodiment, a bit amount may be decreased by using unarycoding or truncated unary coding according to the number of the modes ofthe additional mode set and probability that each mode is to beselected.

According to an embodiment, a same bit may be allocated to theadditional mode set, and each bit may be efficiently coded using contextmodeling and then may be signaled.

According to an embodiment, when an intra prediction mode that is not amode of the MPM mode and the additional mode set is selected, a bit isallocated except for the MPM mode and the modes of the additional modeset, such that the bit may be efficiently coded and then signaled.

According to an embodiment, a block unit flag may be used for theadditional mode set, equally to the MPM flag.

According to an embodiment, whether to use only an MPM or also use anadditional mode set may be determined based on an image.

According to an embodiment, a flag for determining whether to use anadditional mode set may be transmitted in a unit of a frame.

According to an embodiment, whether to use an additional mode set andthe number of modes of the additional mode set may be differentlyapplied, according to sizes of blocks.

The disclosure has been particularly shown and described with referenceto embodiments thereof. In this regard, it will be understood by one ofordinary skill in the art that various changes in form and details maybe made therein without departing from the scope of the disclosure.Therefore, the embodiments should be considered in a descriptive senseonly and not for purposes of limitation. The scope of the disclosure isdefined not by the detailed descriptions of the disclosure but by thefollowing claims, and all differences within the scope will be construedas being included in the disclosure.

Meanwhile, the aforedescribed embodiments of the disclosure can bewritten as a program executable on a computer, and can be implemented ingeneral-use digital computers that execute the program by using acomputer-readable recording medium. Examples of the computer-readablerecording medium include magnetic storage media (e.g., ROM, floppydisks, hard disks, etc.), optical recording media (e.g., CD-ROMs, orDVDs), or the like.

1. A video decoding method comprising: if a first flag indicates not touse any one among a plurality of intra prediction modes included in amost probable mode (MPM) list as an intra prediction mode of a currentblock, obtaining, from a bitstream, a second flag indicating whether touse one among a plurality of intra prediction modes included in anadditional mode list or one among a plurality of remaining intraprediction modes as the intra prediction mode of the current block;configuring the additional mode list using the plurality of intraprediction modes included in the MPM list; if the second flag indicatesto use the one among the plurality of intra prediction modes included inthe additional mode list as the intra prediction mode of the currentblock, determining an intra prediction mode among the plurality of intraprediction modes included in the additional mode list to be the intraprediction mode of the current block; and performing intra prediction onthe current block using the intra prediction mode of the current block,wherein when the plurality of intra prediction modes included in the MPMlist are all angular modes, the additional mode list includes an intraprediction mode having an index decreased by 2 from an index of the oneamong the plurality of intra prediction modes included in the MPM list,wherein when the first flag indicates not to use the any one among theplurality of intra prediction modes included in the MPM list as theintra prediction mode of the current block and the second flag indicatesnot to use any one among the plurality of intra prediction modesincluded in the additional mode list as the intra prediction mode of thecurrent block, the one among the plurality of remaining intra predictionmodes is determined to be the intra prediction mode of the currentblock, and wherein the current block has one of a square shape and anon-square shape.